fix: remove function-level 'import time as _time' that shadowed the module import
The in-function import made _time local to all of _cmd_update_impl, so the orphan-backend reap path (which runs earlier in the function) hit UnboundLocalError before the import line executed. The module-level 'import time as _time' at the top of update_cmd.py already covers the divergence-merge safety tag.
This commit is contained in:
@@ -5895,8 +5895,6 @@ def _cmd_update_impl(args, gateway_mode: bool):
|
||||
or ""
|
||||
).strip()
|
||||
if _cur_branch and _cur_branch != branch:
|
||||
import time as _time
|
||||
|
||||
print(
|
||||
f" ⚠ Checkout is on custom branch '{_cur_branch}' — "
|
||||
f"merging origin/{branch} instead of resetting so local commits survive..."
|
||||
|
||||
Reference in New Issue
Block a user