This is a minor PR fixing #1169 by adding a validate_profile_website method to the users controller. The core of the issue is an unguarded attempt to parse the provided URI with URI.parse, which throws a URI::InvalidURIError on invalid URIs. Here is a preview that everything seems to be working as expected now:
This is a minor PR fixing #1169 by adding a
validate_profile_website
method to the users controller. The core of the issue is an unguarded attempt to parse the provided URI withURI.parse
, which throws aURI::InvalidURIError
on invalid URIs. Here is a preview that everything seems to be working as expected now:Screencast from 23.08.2023 13:31:38.webm
I opted to remove the URI from the parameters and notify the user as I believe this is not severe enough to cause other valid changes to fail.