mercurial/repo.py
changeset 7637 1d54e2f6c0b7
parent 6526 cfeeac24fc1e
child 7873 4a4c7f6a5912
--- a/mercurial/repo.py	Sun Jan 11 23:04:24 2009 -0600
+++ b/mercurial/repo.py	Mon Jan 12 10:42:31 2009 -0600
@@ -8,12 +8,6 @@
 
 from i18n import _
 
-class RepoError(Exception):
-    pass
-
-class NoCapability(RepoError):
-    pass
-
 class repository(object):
     def capable(self, name):
         '''tell whether repo supports named capability.
@@ -31,9 +25,9 @@
     def requirecap(self, name, purpose):
         '''raise an exception if the given capability is not present'''
         if not self.capable(name):
-            raise NoCapability(_('cannot %s; remote repository does not '
-                                 'support the %r capability') %
-                               (purpose, name))
+            raise error.CapabilityError(
+                _('cannot %s; remote repository does not '
+                  'support the %r capability') % (purpose, name))
 
     def local(self):
         return False