Skip to content

Commit

Permalink
added 1 more image check
Browse files Browse the repository at this point in the history
  • Loading branch information
rishavs committed Sep 5, 2018
1 parent 58cc97c commit 468dda8
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion shard.yml
@@ -1,5 +1,5 @@
name: crog
version: 0.1.1
version: 0.1.2

authors:
- your-name-here <your-email-here>
Expand Down
5 changes: 3 additions & 2 deletions src/crog.cr
Expand Up @@ -47,8 +47,9 @@ module Crog
node.xpath_node("//meta[@property='og:image:url']").try &.["content"].to_s ||
node.xpath_node("//meta[@property='og:image']").try &.["content"].to_s ||
node.xpath_node("//meta[@name='twitter:image:src']").try &.["content"].to_s ||
node.xpath_node("//meta[@name='twitter:image']").try &.["content"].to_s
node.xpath_node("//meta[@itemprop='image']").try &.["content"].to_s
node.xpath_node("//meta[@name='twitter:image']").try &.["content"].to_s ||
node.xpath_node("//meta[@itemprop='image']").try &.["content"].to_s ||
node.xpath_node("//img[@src]").try &.["src"].to_s

# wrap($ => $filter($, $('article img[src]'), getSrc)),
# wrap($ => $filter($, $('#content img[src]'), getSrc)),
Expand Down

0 comments on commit 468dda8

Please sign in to comment.