Skip to content

Commit 373fd7c

Browse files
committed
Fixed image getter from Facebook #10
1 parent 808104e commit 373fd7c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Embed/Providers/Facebook.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,8 @@ public function getDescription () {
5454
}
5555

5656
public function getImage () {
57-
if ($imgs = $this->get('image')) {
58-
return current($imgs);
57+
if (($imgs = $this->get('image')) && isset($imgs[0]['url'])) {
58+
return $imgs[0]['url'];
5959
}
6060
}
6161

0 commit comments

Comments
 (0)