Skip to content

Commit

Permalink
Merge pull request #17 from zugazagoitia/desmotivaciones-fix
Browse files Browse the repository at this point in the history
Arreglar regex desmotivaciones
  • Loading branch information
Cadiducho authored Nov 12, 2023
2 parents 7b0cf48 + a5c8345 commit 1a545dd
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public static void getPosts() {
String html = Objects.requireNonNull(response.body()).string();

List<String> carteles = new ArrayList<>();
Matcher image = Pattern.compile("<img\\s.*?src=(?:'|\")\\/\\/img.desmotivaciones.es([^'\">]+)(?:'|\")").matcher(html);
Matcher image = Pattern.compile("<img\\s.*?src=(?:'|\")https?:\\/\\/img.desmotivaciones.es\\/([^'\">]+)(?:'|\")").matcher(html);

while (image.find()) {
carteles.add(image.group(1));
Expand Down

0 comments on commit 1a545dd

Please sign in to comment.