From: Niki Roo Date: Fri, 1 May 2020 11:05:46 +0000 (+0200) Subject: e621: better title X-Git-Tag: fanfix-swing-1.1.0~25 X-Git-Url: https://git.nikiroo.be/?a=commitdiff_plain;h=ac345e4ebce884f983218f02051031c9fdaa1fc0;p=fanfix-swing.git e621: better title --- diff --git a/src/be/nikiroo/fanfix/supported/E621.java b/src/be/nikiroo/fanfix/supported/E621.java index c3a261bd..602cd363 100644 --- a/src/be/nikiroo/fanfix/supported/E621.java +++ b/src/be/nikiroo/fanfix/supported/E621.java @@ -186,7 +186,7 @@ class E621 extends BasicSupport { } source = new URL(base + "/pools/" + poolNumber); } catch (NumberFormatException e) { - // Not a simple ppol, skip + // Not a simple pool, skip } catch (MalformedURLException e) { // Cannot happen } @@ -247,19 +247,19 @@ class E621 extends BasicSupport { title = el.text().trim(); } - for (String s : new String[] { "e621", "-", "e621" }) { + for (String s : new String[] { "e621", "-", "e621", "Pool", "-" }) { if (title.startsWith(s)) { title = title.substring(s.length()).trim(); } if (title.endsWith(s)) { title = title.substring(0, title.length() - s.length()).trim(); } - } if (isSearchOrSet(getSource())) { title = title.isEmpty() ? "e621" : "[e621] " + title; } + return title; }