fix for bug #1404 Share Updates to skip gif images in URL Preview
git-svn-id: https://svn.research-infrastructures.eu/d4science/gcube/trunk/portlets/user/share-updates@120290 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
c296d54710
commit
d0a4578f42
|
@ -218,8 +218,13 @@ public class TextTransfromUtils {
|
|||
for (int i = 0; i < upTo; i++) {
|
||||
if (imgs[i].hasAttribute("src")) {
|
||||
String imageUrl = getImageUrlFromSrcAttribute(pageURL, imgs[i].getAttributeByName("src"));
|
||||
images.add(imageUrl);
|
||||
_log.trace("[FOUND image] " + imageUrl);
|
||||
if (imageUrl.endsWith(".gif") || imageUrl.endsWith(".GIF"))
|
||||
_log.trace("[Gif image] SKIP " + imageUrl);
|
||||
else {
|
||||
images.add(imageUrl);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
return images;
|
||||
|
|
Loading…
Reference in New Issue