Skip to content

Commit

Permalink
made it so that only owner can delete alarms
Browse files Browse the repository at this point in the history
  • Loading branch information
MarkisDev committed Jul 21, 2023
1 parent 2dd21eb commit c04a8d9
Showing 1 changed file with 8 additions and 9 deletions.
17 changes: 8 additions & 9 deletions lib/app/modules/home/views/home_view.dart
Original file line number Diff line number Diff line change
Expand Up @@ -616,16 +616,15 @@ class HomeView extends GetView<HomeController> {
style: Theme.of(context).textTheme.bodyMedium,
),
),
PopupMenuItem<
int>(
value:
1,
child:
Text(
"Delete Alarm",
style: Theme.of(context).textTheme.bodyMedium,
if (alarm.isSharedAlarmEnabled &&
alarm.ownerId == controller.userModel.value!.id)
PopupMenuItem<int>(
value: 1,
child: Text(
"Delete Alarm",
style: Theme.of(context).textTheme.bodyMedium,
),
),
),
];
},
),
Expand Down

0 comments on commit c04a8d9

Please sign in to comment.