Skip to content

Commit

Permalink
Resolve readonly database bug for activity duplication to new activity.
Browse files Browse the repository at this point in the history
  • Loading branch information
marc-vdm committed Nov 8, 2023
1 parent deb1a81 commit 231f26c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions activity_browser/ui/tables/inventory.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,9 @@ def contextMenuEvent(self, event) -> None:
if len(self.selectedIndexes()) > 1:
act = 'activities'
self.duplicate_activity_new_loc_action.setEnabled(False)
elif len(self.selectedIndexes()) == 1 and self.db_read_only:
act = 'activity'
self.duplicate_activity_new_loc_action.setEnabled(False)
else:
act = 'activity'
self.duplicate_activity_new_loc_action.setEnabled(True)
Expand Down

0 comments on commit 231f26c

Please sign in to comment.