Reverting checkLink changes
git-svn-id: https://svn.research-infrastructures.eu/d4science/gcube/trunk/portlets/user/share-updates@176812 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
563e77551c
commit
d0aad689dc
|
@ -731,11 +731,9 @@ public class ShareUpdateServiceImpl extends RemoteServiceServlet implements Shar
|
|||
LinkPreview toReturn = null;
|
||||
_log.info("to check " + linkToCheck);
|
||||
//look for a url in text
|
||||
URL url = URLToken.isURL(linkToCheck);
|
||||
if (url == null) {
|
||||
linkToCheck = Utils.extractURL(linkToCheck);
|
||||
if (linkToCheck == null)
|
||||
return null; //no url
|
||||
}
|
||||
linkToCheck = url.toString();
|
||||
|
||||
String[] schemes = {"http","https"};
|
||||
UrlValidator urlValidator = new UrlValidator(schemes);
|
||||
|
|
Loading…
Reference in New Issue