Readonly databases do not necessarily have commit methods
svn: r15460
This commit is contained in:
parent
7c4d945da6
commit
ed73f393ed
@ -77,6 +77,7 @@ class EditEvent(EditPrimary):
|
||||
self._init_event()
|
||||
|
||||
def _init_event(self):
|
||||
if not self.db.readonly:
|
||||
self.commit_event = self.db.commit_event
|
||||
|
||||
def empty_object(self):
|
||||
@ -302,6 +303,7 @@ class EditPersonEvent(EditEvent):
|
||||
EditEvent.__init__(self, dbstate, uistate, track, event, callback)
|
||||
|
||||
def _init_event(self):
|
||||
if not self.db.readonly:
|
||||
self.commit_event = self.db.commit_personal_event
|
||||
|
||||
def get_custom_events(self):
|
||||
@ -313,6 +315,7 @@ class EditFamilyEvent(EditEvent):
|
||||
EditEvent.__init__(self, dbstate, uistate, track, event, callback)
|
||||
|
||||
def _init_event(self):
|
||||
if not self.db.readonly:
|
||||
self.commit_event = self.db.commit_family_event
|
||||
|
||||
def get_custom_events(self):
|
||||
|
Loading…
Reference in New Issue
Block a user