From: Neil Date: Sat, 17 Nov 2012 15:26:22 +0000 (+0200) Subject: remove self.repository in favour of self.branch.repository X-Git-Url: https://git.ctpug.org.za/?a=commitdiff_plain;h=3c8a6326b1cc6664f2b10bdeffa44d1ecd71904d;p=bzrirker.git remove self.repository in favour of self.branch.repository --- diff --git a/irkerhook.py b/irkerhook.py index d58b194..4eecd21 100644 --- a/irkerhook.py +++ b/irkerhook.py @@ -15,13 +15,12 @@ class IrkerSender(object): def __init__(self, branch, revision_id, config): self.config = config self.branch = branch - self.repository = branch.repository self._revision_id = revision_id self.revision = None self.revno = None def _setup_revision_and_revno(self): - self.revision = self.repository.get_revision(self._revision_id) + self.revision = self.branch.repository.get_revision(self._revision_id) self.revno = self.branch.revision_id_to_revno(self._revision_id) def _format(self): @@ -99,7 +98,7 @@ class IrkerSender(object): """Send the info to irkerd. """ self.branch.lock_read() - self.repository.lock_read() + self.branch.repository.lock_read() # These should become configurable at some point default_server = 'localhost' IRKER_PORT = 6659 @@ -125,7 +124,7 @@ class IrkerSender(object): finally: sock.close() finally: - self.repository.unlock() + self.branch.repository.unlock() self.branch.unlock() opt_irker_channels = Option('irker_channels',