forked from Ivasoft/mattermost-mobile
Various fixes: (#4466)
* Dispatch REHYDRATED if already hydrated after getStoredState call * Empty/null prev version is valid * Update iOS target to 11.0 Co-authored-by: Miguel Alatzar <this.migbot@gmail.com>
This commit is contained in:
@@ -885,7 +885,7 @@ export const getDefaultChannelForTeams: (a: GlobalState) => RelationOneToOne<Tea
|
||||
});
|
||||
|
||||
export const getMyFirstChannelForTeams: (a: GlobalState) => RelationOneToOne<Team, Channel> = createSelector(getAllChannels, getMyChannelMemberships, getMyTeams, getCurrentUser, (allChannels: IDMappedObjects<Channel>, myChannelMemberships: RelationOneToOne<Channel, ChannelMembership>, myTeams: Array<Team>, currentUser: UserProfile): RelationOneToOne<Team, Channel> => {
|
||||
const locale = currentUser.locale || General.DEFAULT_LOCALE;
|
||||
const locale = currentUser?.locale || General.DEFAULT_LOCALE;
|
||||
const result: RelationOneToOne<Team, Channel> = {};
|
||||
|
||||
for (const team of myTeams) {
|
||||
|
||||
@@ -240,6 +240,8 @@ export default function configureStore(storage: any, preloadedState: any = {}, o
|
||||
});
|
||||
store.dispatch({type: General.REHYDRATED});
|
||||
AsyncStorage.multiRemove(storeKeys);
|
||||
} else if (store.getState()._persist?.rehydrated) { // eslint-disable-line no-underscore-dangle
|
||||
store.dispatch({type: General.REHYDRATED});
|
||||
} else {
|
||||
let executed = false;
|
||||
const unsubscribe = store.subscribe(() => {
|
||||
|
||||
@@ -90,7 +90,7 @@ export function validatePreviousVersion(previousVersion) {
|
||||
INVALID_VERSIONS.push('1.31.0', '1.31.1');
|
||||
}
|
||||
|
||||
if (!previousVersion || INVALID_VERSIONS.includes(previousVersion)) {
|
||||
if (INVALID_VERSIONS.includes(previousVersion)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@@ -945,7 +945,7 @@
|
||||
"$(SRCROOT)/UploadAttachments/UploadAttachments",
|
||||
);
|
||||
INFOPLIST_FILE = Mattermost/Info.plist;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 10.3;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
|
||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
|
||||
OTHER_CFLAGS = (
|
||||
"$(inherited)",
|
||||
@@ -987,7 +987,7 @@
|
||||
"$(SRCROOT)/UploadAttachments/UploadAttachments",
|
||||
);
|
||||
INFOPLIST_FILE = Mattermost/Info.plist;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 10.3;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
|
||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
|
||||
OTHER_CFLAGS = (
|
||||
"$(inherited)",
|
||||
@@ -1035,7 +1035,7 @@
|
||||
GCC_C_LANGUAGE_STANDARD = gnu11;
|
||||
HEADER_SEARCH_PATHS = "$(SRCROOT)/UploadAttachments/UploadAttachments";
|
||||
INFOPLIST_FILE = MattermostShare/Info.plist;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 10.3;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
|
||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks";
|
||||
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
|
||||
MTL_FAST_MATH = YES;
|
||||
@@ -1081,7 +1081,7 @@
|
||||
GCC_C_LANGUAGE_STANDARD = gnu11;
|
||||
HEADER_SEARCH_PATHS = "$(SRCROOT)/UploadAttachments/UploadAttachments";
|
||||
INFOPLIST_FILE = MattermostShare/Info.plist;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 10.3;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
|
||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks";
|
||||
MTL_FAST_MATH = YES;
|
||||
OTHER_CFLAGS = (
|
||||
@@ -1123,7 +1123,7 @@
|
||||
DEVELOPMENT_TEAM = UQ8HT4Q2XM;
|
||||
GCC_C_LANGUAGE_STANDARD = gnu11;
|
||||
INFOPLIST_FILE = NotificationService/Info.plist;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 10.3;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
|
||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks";
|
||||
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
|
||||
MTL_FAST_MATH = YES;
|
||||
@@ -1167,7 +1167,7 @@
|
||||
DEVELOPMENT_TEAM = UQ8HT4Q2XM;
|
||||
GCC_C_LANGUAGE_STANDARD = gnu11;
|
||||
INFOPLIST_FILE = NotificationService/Info.plist;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 10.3;
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
|
||||
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks";
|
||||
MTL_FAST_MATH = YES;
|
||||
OTHER_CFLAGS = (
|
||||
|
||||
Reference in New Issue
Block a user