Skip to content

Commit

Permalink
Merge pull request #1382 from ardriveapp/PE-4665
Browse files Browse the repository at this point in the history
PE-4665: Snapshot creation disabled without ARs
  • Loading branch information
matibat authored Sep 26, 2023
2 parents ea9f1c7 + 6636abd commit 90f4685
Showing 1 changed file with 3 additions and 8 deletions.
11 changes: 3 additions & 8 deletions lib/components/new_button/new_button.dart
Original file line number Diff line number Diff line change
Expand Up @@ -304,8 +304,7 @@ class NewButton extends StatelessWidget {
icon: ArDriveIcons.iconAttachDrive(size: defaultIconSize),
),
if (driveDetailState is DriveDetailLoadSuccess && drive != null) ...[
if (driveDetailState.currentDrive.privacy == 'public' &&
drive != null)
if (driveDetailState.currentDrive.privacy == 'public')
ArDriveNewButtonItem(
onClick: () {
promptToCreateManifest(
Expand All @@ -319,8 +318,7 @@ class NewButton extends StatelessWidget {
name: appLocalizations.createManifest,
icon: ArDriveIcons.tournament(size: defaultIconSize),
),
if (context.read<ConfigService>().config.enableQuickSyncAuthoring &&
drive != null)
if (context.read<ConfigService>().config.enableQuickSyncAuthoring)
ArDriveNewButtonItem(
onClick: () {
promptToCreateSnapshot(
Expand All @@ -329,10 +327,7 @@ class NewButton extends StatelessWidget {
);
},
isDisabled: !driveDetailState.hasWritePermissions ||
driveDetailState.driveIsEmpty ||
!profile.hasMinimumBalanceForUpload(
minimumWalletBalance: minimumWalletBalance,
),
driveDetailState.driveIsEmpty,
name: appLocalizations.createSnapshot,
icon: ArDriveIcons.iconCreateSnapshot(size: defaultIconSize),
),
Expand Down

0 comments on commit 90f4685

Please sign in to comment.