# HG changeset patch # User Steve Losh # Date 1255039964 14400 # Node ID 0d213b070f7908b4bcb13a032a725caa6447c3b3 # Parent 022175cc8a90a63c3150b2b9a0dd754ed32727ad Mark the internal object commit and delete methods as private. diff -r 022175cc8a90 -r 0d213b070f79 review/api.py --- a/review/api.py Thu Oct 08 18:08:06 2009 -0400 +++ b/review/api.py Thu Oct 08 18:12:44 2009 -0400 @@ -215,11 +215,11 @@ if existing: if not force: raise SignoffExists - existing[0].delete(self.ui, self.repo) + existing[0]._delete(self.ui, self.repo) signoff = ReviewSignoff(self.ui.username(), datetime.utcnow(), self.node, opinion, message) - signoff.commit(self.ui, self.repo) + signoff._commit(self.ui, self.repo) def add_comment(self, message, filename='', lines=[]): """Add (and commit) a comment for the given file and lines. @@ -240,7 +240,7 @@ comment = ReviewComment(self.ui.username(), datetime.utcnow(), self.node, filename, lines, message) - comment.commit(self.ui, self.repo) + comment._commit(self.ui, self.repo) def full_diffs(self, filenames=None, opts={}): """Return full diffs of the given files (or all files). @@ -305,7 +305,7 @@ self.commit_message = commit_message self.delete_message = delete_message - def commit(self, ui, repo): + def _commit(self, ui, repo): """Write and commit this object to the given repo.""" path = os.path.join(repo.root, self.node, self.container) @@ -322,7 +322,7 @@ cmdutil.commit(ui, repo, _commitfunc, [objectpath], { 'message': self.commit_message % self.node, 'addremove': True, }) - def delete(self, ui, repo): + def _delete(self, ui, repo): """Delete and commit this object in the given repo.""" if not self.delete_message: