Skip to content
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions apps/forms/shiny.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,10 +105,10 @@ def clean_path(self):
# If new path matches current path, it is valid.
if self.instance and getattr(self.instance, "path", None) == path:
return path
# Verify that path starts with "/home"
# Verify that path starts with "/home" or "/srv"
path = path.strip().rstrip("/").lower().replace(" ", "")
if not path.startswith("/home"):
self.add_error("path", 'Path must start with "/home"')
if not path.startswith("/home") and not path.startswith("/srv"):
self.add_error("path", 'Path must start with "/home" or "/srv"')

return path

Expand Down
Loading