Skip to content

Commit

Permalink
chore: Merge 4.49.2 into master (#5740)
Browse files Browse the repository at this point in the history
  • Loading branch information
diegolmello authored Jun 13, 2024
2 parents 1119492 + 658b526 commit ff15e2b
Show file tree
Hide file tree
Showing 10 changed files with 35 additions and 11 deletions.
2 changes: 1 addition & 1 deletion android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ android {
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
versionCode VERSIONCODE as Integer
versionName "4.49.1"
versionName "4.49.2"
vectorDrawables.useSupportLibrary = true
if (!isFoss) {
manifestPlaceholders = [BugsnagAPIKey: BugsnagAPIKey as String]
Expand Down
7 changes: 7 additions & 0 deletions android/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -79,4 +79,11 @@
</intent-filter>
</activity>
</application>

<queries>
<intent>
<action android:name="android.intent.action.VIEW" />
<data android:mimeType="*/*" />
</intent>
</queries>
</manifest>
5 changes: 2 additions & 3 deletions app/containers/Toast.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,8 @@ const styles = StyleSheet.create({
},
text: {
fontSize: 14,
// jest error: TypeError: Cannot read property 'textRegular' of undefined
...sharedStyles?.textRegular,
...sharedStyles?.textAlignCenter
...sharedStyles.textRegular,
...sharedStyles.textAlignCenter
}
});

Expand Down
3 changes: 2 additions & 1 deletion app/lib/methods/subscriptions/room.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import { IDDPMessage } from '../../../definitions/IDDPMessage';
import sdk from '../../services/sdk';
import { readMessages } from '../readMessages';
import { loadMissedMessages } from '../loadMissedMessages';
import { updateLastOpen } from '../updateLastOpen';

const WINDOW_TIME = 1000;

Expand Down Expand Up @@ -74,7 +75,7 @@ export default class RoomSubscription {

unsubscribe = async () => {
console.log(`[RCRN] Unsubscribing from room ${this.rid}`);
readMessages(this.rid, new Date(), true).catch(e => console.log(e));
updateLastOpen(this.rid);
this.isAlive = false;
reduxStore.dispatch(unsubscribeRoom(this.rid));
if (this.promises) {
Expand Down
17 changes: 17 additions & 0 deletions app/lib/methods/updateLastOpen.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import database from '../database';
import log from './helpers/log';
import { TSubscriptionModel } from '../../definitions';

export async function updateLastOpen(rid: string, lastOpen = new Date()): Promise<void> {
try {
const db = database.active;
const subscription = await db.get('subscriptions').find(rid);
await db.write(async () => {
await subscription.update((s: TSubscriptionModel) => {
s.lastOpen = lastOpen;
});
});
} catch (e) {
log(e);
}
}
2 changes: 1 addition & 1 deletion app/views/Styles.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { Platform, StyleSheet, TextStyle } from 'react-native';

import { MAX_SCREEN_CONTENT_WIDTH } from '../lib/constants';
import { MAX_SCREEN_CONTENT_WIDTH } from '../lib/constants/tablet';

const defaultTextStyle: TextStyle = {
textAlign: 'left',
Expand Down
4 changes: 2 additions & 2 deletions ios/RocketChatRN.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -2910,7 +2910,7 @@
INFOPLIST_FILE = NotificationService/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks";
MARKETING_VERSION = 4.49.1;
MARKETING_VERSION = 4.49.2;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
OTHER_SWIFT_FLAGS = "$(inherited) -D EXPO_CONFIGURATION_DEBUG";
Expand Down Expand Up @@ -2950,7 +2950,7 @@
INFOPLIST_FILE = NotificationService/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 12.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks";
MARKETING_VERSION = 4.49.1;
MARKETING_VERSION = 4.49.2;
MTL_FAST_MATH = YES;
OTHER_SWIFT_FLAGS = "$(inherited) -D EXPO_CONFIGURATION_RELEASE";
PRODUCT_BUNDLE_IDENTIFIER = chat.rocket.reactnative.NotificationService;
Expand Down
2 changes: 1 addition & 1 deletion ios/RocketChatRN/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>4.49.1</string>
<string>4.49.2</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleURLTypes</key>
Expand Down
2 changes: 1 addition & 1 deletion ios/ShareRocketChatRN/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
<key>CFBundlePackageType</key>
<string>XPC!</string>
<key>CFBundleShortVersionString</key>
<string>4.49.1</string>
<string>4.49.2</string>
<key>CFBundleVersion</key>
<string>1</string>
<key>KeychainGroup</key>
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "rocket-chat-reactnative",
"version": "4.49.1",
"version": "4.49.2",
"private": true,
"scripts": {
"start": "react-native start",
Expand Down

0 comments on commit ff15e2b

Please sign in to comment.