Skip to content

Fix implied photo parsing #191

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Aug 23, 2018
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Always resolveUrl before returning implied photo
  • Loading branch information
gRegorLove committed Aug 7, 2018
commit 04aadf23cdfdc41778819ec9727aac9fe8aac818
4 changes: 2 additions & 2 deletions Mf2/Parser.php
Original file line number Diff line number Diff line change
Expand Up @@ -1157,12 +1157,12 @@ public function parseImpliedPhoto(\DOMElement $e) {

// img.h-x[src]
if ($e->tagName == 'img') {
return $e->getAttribute('src');
return $this->resolveUrl($e->getAttribute('src'));
}

// object.h-x[data]
if ($e->tagName == 'object' && $e->hasAttribute('data')) {
return $e->getAttribute('data');
return $this->resolveUrl($e->getAttribute('data'));
}

$xpaths = array(
Expand Down