Mostly, because a regex is easier and cleaner (imho).
We'd still have to check if the hostname is `www.flickr.com` or flickr.com` and not www.some-weird-and-fake-flickr.com/website .
Although it wouldn't be really harmfull, it's still better to avoid those kind of links (I think)

We'd also still have to check if it's a photo/set url that we can understand, which would probably have to be a regex.

I found it cleaner to just remove url.parse in it's entirety and use one regex.