fix(mobile): make user.memoryEnable optional (#3680)

* chore(server): avoid breaking changes

* generate api

* mobile app
This commit is contained in:
Alex
2023-08-14 12:52:06 -05:00
committed by GitHub
parent b1b215f083
commit 0d80ae3a91
8 changed files with 25 additions and 16 deletions

View File

@@ -342,10 +342,11 @@ class HomePage extends HookConsumerWidget {
listener: selectionListener,
selectionActive: selectionEnabledHook.value,
onRefresh: refreshAssets,
topWidget:
(currentUser != null && currentUser.memoryEnabled)
? const MemoryLane()
: const SizedBox(),
topWidget: (currentUser != null &&
currentUser.memoryEnabled != null &&
currentUser.memoryEnabled!)
? const MemoryLane()
: const SizedBox(),
),
error: (error, _) => Center(child: Text(error.toString())),
loading: buildLoadingIndicator,

View File

@@ -44,7 +44,7 @@ class User {
bool isPartnerSharedWith;
bool isAdmin;
String profileImagePath;
bool memoryEnabled;
bool? memoryEnabled;
@Backlink(to: 'owner')
final IsarLinks<Album> albums = IsarLinks<Album>();
@Backlink(to: 'sharedUsers')