##// END OF EJS Templates
journal: don't show "error" popup when navigating away from page while lazy info is loading...
journal: don't show "error" popup when navigating away from page while lazy info is loading The "error" box would pop up in the Journal view when quickly pointing and clicking a link while the info was loading. This fix might prevent showing valid error messages in some browsers.

File last commit:

r2543:03a77098 beta
r3553:72c89171 beta
Show More
workdir.py
21 lines | 672 B | text/x-python | PythonLexer
from rhodecode.lib.vcs.backends.base import BaseWorkdir
from rhodecode.lib.vcs.exceptions import BranchDoesNotExistError
from rhodecode.lib.vcs.utils.hgcompat import hg_merge
class MercurialWorkdir(BaseWorkdir):
def get_branch(self):
return self.repository._repo.dirstate.branch()
def get_changeset(self):
return self.repository.get_changeset()
def checkout_branch(self, branch=None):
if branch is None:
branch = self.repository.DEFAULT_BRANCH_NAME
if branch not in self.repository.branches:
raise BranchDoesNotExistError
hg_merge.update(self.repository._repo, branch, False, False, None)