Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix for issue preventing validation of url with only whitespace #11549

Open
wants to merge 1 commit into
base: dev/7.6.x
Choose a base branch
from
Open
Changes from all 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
8 changes: 6 additions & 2 deletions arches/app/datatypes/url.py
Original file line number Diff line number Diff line change
Expand Up @@ -307,8 +307,12 @@ def pre_tile_save(self, tile, nodeid):
def clean(self, tile, nodeid):
if data := tile.data[nodeid]:
try:
if not any([val.strip() for val in data.values()]):
tile.data[nodeid] = None
if not any([data.values()]):
tile.data[nodeid] = None

if not data["url_label"].strip():
tile.data[nodeid]["url_label"] = None

except:
pass # Let self.validate handle malformed data

Expand Down