X-Git-Url: http://git.nikiroo.be/?a=blobdiff_plain;f=supported%2FE621.java;h=a8ea6e6cf3df1b2bf82f4c1aedfea800f05851fe;hb=ffcc07e58b86c06c1a743b2d677e4a0c88477c30;hp=602cd36309250e03de7291c4f46784b7171ccc93;hpb=36c35b92f704ed40f3ce80501dc96cce73d39ceb;p=nikiroo-utils.git diff --git a/supported/E621.java b/supported/E621.java index 602cd36..a8ea6e6 100644 --- a/supported/E621.java +++ b/supported/E621.java @@ -292,6 +292,28 @@ class E621 extends BasicSupport { builder.append(" ").append(tab[i]); } } + + if (builder.length() == 0) { + try { + String poolNumber = getSource().getPath() + .substring("/pools/".length()); + String url = "https://e621.net/posts" + "?tags=pool%3A" + + poolNumber; + + Document page1 = DataUtil.load(Instance.getInstance() + .getCache().open(getSource(), null, false), "UTF-8", + url); + for (Element el : page1.getElementsByClass("search-tag")) { + if (el.attr("itemprop").equals("author")) { + if (builder.length() > 0) { + builder.append(", "); + } + builder.append(el.text().trim()); + } + } + } catch (Exception e) { + } + } } return builder.toString();