def can_commit(self, commit=True): if commit: commitsession() return self
def save(self, commit=True): session().add(self) x = current_app if commit: commitsession() return self
def commit(self): return commitsession()
def delete(self): x = current_app session().delete(self) commitsession()