Skip to content

Commit

Permalink
Checked user permission for open note
Browse files Browse the repository at this point in the history
  • Loading branch information
cp-nirali-s committed Nov 27, 2024
1 parent 980073b commit 005a3fb
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,9 @@ class ExpenseDetailsViewModel: BaseViewModel, ObservableObject {
}

func handleNoteTap() {
guard let expense else { return }
showAddNoteEditor = expense.isActive
guard let expense, expense.isActive, let userId = preference.user?.id,
let group, group.members.contains(userId) else { return }
showAddNoteEditor = true
}

func handleEditBtnAction() {
Expand Down

0 comments on commit 005a3fb

Please sign in to comment.