-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #214 from internxt/releases/1.5.31
Mobile 1.5.31 release
- Loading branch information
Showing
52 changed files
with
249 additions
and
63 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file modified
BIN
+2.27 MB
(33000%)
android/app/src/main/res/drawable-hdpi/splashscreen_image.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+2.27 MB
(33000%)
android/app/src/main/res/drawable-mdpi/splashscreen_image.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+2.27 MB
(33000%)
android/app/src/main/res/drawable-xhdpi/splashscreen_image.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+2.27 MB
(33000%)
android/app/src/main/res/drawable-xxhdpi/splashscreen_image.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+2.27 MB
(33000%)
android/app/src/main/res/drawable-xxxhdpi/splashscreen_image.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+9.36 KB
(880%)
android/app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+5 KB
(710%)
android/app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+18.1 KB
(1200%)
android/app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+18.1 KB
(810%)
android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+48.7 KB
(2200%)
android/app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+49.4 KB
(1400%)
android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+96.3 KB
(3100%)
android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+100 KB
(2000%)
android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file modified
BIN
+110 Bytes
(120%)
ios/Internxt/Images.xcassets/AppIcon.appiconset/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+485 Bytes
(150%)
ios/Internxt/Images.xcassets/AppIcon.appiconset/[email protected]
Oops, something went wrong.
Binary file modified
BIN
+892 Bytes
(170%)
ios/Internxt/Images.xcassets/AppIcon.appiconset/[email protected]
Oops, something went wrong.
Binary file modified
BIN
+284 Bytes
(140%)
ios/Internxt/Images.xcassets/AppIcon.appiconset/[email protected]
Oops, something went wrong.
Binary file modified
BIN
+931 Bytes
(170%)
ios/Internxt/Images.xcassets/AppIcon.appiconset/[email protected]
Oops, something went wrong.
Binary file modified
BIN
+1.67 KB
(190%)
ios/Internxt/Images.xcassets/AppIcon.appiconset/[email protected]
Oops, something went wrong.
Binary file modified
BIN
+485 Bytes
(150%)
ios/Internxt/Images.xcassets/AppIcon.appiconset/[email protected]
Oops, something went wrong.
Binary file modified
BIN
+1.41 KB
(180%)
ios/Internxt/Images.xcassets/AppIcon.appiconset/[email protected]
Oops, something went wrong.
Binary file modified
BIN
+2.28 KB
(190%)
ios/Internxt/Images.xcassets/AppIcon.appiconset/[email protected]
Oops, something went wrong.
Binary file modified
BIN
+2.28 KB
(190%)
ios/Internxt/Images.xcassets/AppIcon.appiconset/[email protected]
Oops, something went wrong.
Binary file modified
BIN
+5.05 KB
(230%)
ios/Internxt/Images.xcassets/AppIcon.appiconset/[email protected]
Oops, something went wrong.
Binary file modified
BIN
+1.13 KB
(170%)
ios/Internxt/Images.xcassets/AppIcon.appiconset/[email protected]
Oops, something went wrong.
Binary file modified
BIN
+3.77 KB
(220%)
ios/Internxt/Images.xcassets/AppIcon.appiconset/[email protected]
Oops, something went wrong.
Binary file modified
BIN
+4.35 KB
(230%)
ios/Internxt/Images.xcassets/AppIcon.appiconset/[email protected]
Oops, something went wrong.
Binary file modified
BIN
+241 KB
(1000%)
ios/Internxt/Images.xcassets/AppIcon.appiconset/[email protected]
Oops, something went wrong.
Binary file modified
BIN
+2.27 MB
(33000%)
ios/Internxt/Images.xcassets/SplashScreen.imageset/image.png
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
import { driveFileService } from '@internxt-mobile/services/drive/file'; | ||
import { driveFolderService } from '@internxt-mobile/services/drive/folder'; | ||
import asyncStorageService from '@internxt-mobile/services/AsyncStorageService'; | ||
import { AsyncStorageKey } from '@internxt-mobile/types/index'; | ||
import { driveLocalDB } from '@internxt-mobile/services/drive/database'; | ||
import errorService from '@internxt-mobile/services/ErrorService'; | ||
import _ from 'lodash'; | ||
|
||
export const getModifiedDriveItemsAndUpdateLocalCache = async () => { | ||
const lastUpdatedAt = (await asyncStorageService.getItem(AsyncStorageKey.LastUpdatedAt)) ?? new Date().toISOString(); | ||
|
||
const [modifiedFiles, modifiedFolders] = await Promise.all([ | ||
driveFileService.getModifiedFiles({ | ||
updatedAt: lastUpdatedAt, | ||
status: 'ALL', | ||
}), | ||
driveFolderService.getModifiedFolders({ | ||
updatedAt: lastUpdatedAt, | ||
status: 'ALL', | ||
}), | ||
]).catch((error) => { | ||
errorService.reportError(error); | ||
return [[], []]; | ||
}); | ||
|
||
if (!modifiedFiles || !modifiedFolders || (!modifiedFiles.length && !modifiedFolders.length)) return; | ||
|
||
const modifiedFilesIds = modifiedFiles.map((file) => file.id); | ||
const modifiedFoldersIds = modifiedFolders.map((folder) => folder.id); | ||
|
||
for (const modifiedFileId of modifiedFilesIds) { | ||
await driveLocalDB.deleteItem({ id: modifiedFileId }); | ||
} | ||
|
||
for (const modifiedFolderId of modifiedFoldersIds) { | ||
await driveLocalDB.deleteFolderRecord(modifiedFolderId); | ||
} | ||
|
||
// Get the last updatedAt date from the modified files and folders | ||
let lastUpdatedAtFromModifiedFiles; | ||
let lastUpdatedAtFromModifiedFolders; | ||
|
||
if (modifiedFiles.length) lastUpdatedAtFromModifiedFiles = _.maxBy(modifiedFiles, 'updatedAt')?.updatedAt; | ||
|
||
if (modifiedFolders.length) | ||
lastUpdatedAtFromModifiedFolders = _.maxBy(modifiedFolders, 'updatedAt')?.updatedAt.toString(); | ||
|
||
// Get the most recent date | ||
const newLastUpdatedAt = _.max([lastUpdatedAtFromModifiedFiles, lastUpdatedAtFromModifiedFolders]); | ||
|
||
await asyncStorageService.saveItem(AsyncStorageKey.LastUpdatedAt, newLastUpdatedAt ?? new Date().toISOString()); | ||
}; |
Oops, something went wrong.