Skip to content
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
Next Next commit
cs-fixer fixes
  • Loading branch information
Javier Garcia committed May 25, 2018
commit 65a594d2713b6ff876ca0a1d230404a0d160b6c9
10 changes: 5 additions & 5 deletions src/PhpWord/Shared/Html.php
Original file line number Diff line number Diff line change
Expand Up @@ -655,7 +655,7 @@ private static function parseImage($node, $element)
break;
}
}
$origin_src= $src;
$originSrc = $src;
if (strpos($src, 'data:image') !== false) {
$tmpDir = Settings::getTempDir() . '/';

Expand Down Expand Up @@ -692,10 +692,10 @@ private static function parseImage($node, $element)
}
}

if (is_file($src)){
$newElement = $element->addImage($src, $style);
}else{
throw new \Exception("Could not load image $origin_src");
if (is_file($src)) {
$newElement = $element->addImage($src, $style);
} else {
throw new \Exception("Could not load image $originSrc");
}

return $newElement;
Expand Down