refactored shortened_url and visit models