diff --git a/mercurial/commands.py b/mercurial/commands.py --- a/mercurial/commands.py +++ b/mercurial/commands.py @@ -5701,7 +5701,7 @@ def update(ui, repo, node=None, rev=None # with no argument, we also move the current bookmark, if any movemarkfrom = None - if node is None or node == '': + if rev is None or node == '': movemarkfrom = repo['.'].node() # if we defined a bookmark, we have to remember the original bookmark name