更好的检查子路径逻辑
This commit is contained in:
parent
f0ff1f2c64
commit
9945d5048a
@ -540,6 +540,9 @@ def custom_path_check(path: str)->bool:
|
||||
print("ilegal custom path: {}\npath must not be empty\ndeploy on root url".format(path))
|
||||
return False
|
||||
if path[0] == '/':
|
||||
if len(path) == 1:
|
||||
print("deploy on root url")
|
||||
return False
|
||||
if path[1] != '/':
|
||||
print("deploy on sub-path {}".format(path))
|
||||
return True
|
||||
|
Loading…
x
Reference in New Issue
Block a user