Fix some IDs and update utils
[gofetch.git] / src / be / nikiroo / gofetch / support / LWN.java
index 144fdc90514039656168bf41fef8b850a027d4fe..eac12e5c239c37aa921d2945333d1b7fbc4c4e9a 100644 (file)
@@ -53,7 +53,12 @@ public class LWN extends BasicSupport {
 
        @Override
        protected String getArticleId(Document doc, Element article) {
-               return getArticleIntUrl(doc, article).replaceAll("[^0-9]", "");
+               String id = getArticleIntUrl(doc, article).replaceAll("[^0-9]", "");
+               while (id.length() < 10) {
+                       id = "0" + id;
+               }
+
+               return id;
        }
 
        @Override