Skip to content

armgit / zulip

Public Imported from GitHub
0

Zulip server and web application. Open-source team chat that helps teams stay productive and focused.

ruff: Fix RUF071 `os.path.commonprefix()` compares strings character-by-character.

Anders Kaseorg127f8e77965d
diff --git a/scripts/restart-server b/scripts/restart-server
index c4b49ba7921..a4127044d2f 100755
--- a/scripts/restart-server
+++ b/scripts/restart-server
@@ -356,7 +356,7 @@ print(OKGREEN + f"Zulip {action}ed successfully!" + ENDC)
if change_symlink and "PWD" in os.environ:
for symlink in [last_symlink, current_symlink]:
- if os.path.commonprefix([os.environ["PWD"], symlink]) == symlink:
+ if os.path.commonpath([os.environ["PWD"], symlink]) == symlink:
print(
"""
{}Your shell entered its current directory through a symlink: