Skip to content

Commit

Permalink
Rename variable
Browse files Browse the repository at this point in the history
The href is converted to path.
  • Loading branch information
glubsy committed Jan 25, 2021
1 parent 8f5410c commit 435d7f5
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/_h5ai/private/php/core/class-context.php
Original file line number Diff line number Diff line change
Expand Up @@ -252,16 +252,16 @@ public function get_thumbs($requests) {
$hrefs = [];
$thumbs = [];
foreach ($requests as $req) {
$href = $this->to_path($req['href']);
$path = $this->to_path($req['href']);
if (!array_key_exists($href, $thumbs)) {
$thumbs[$href] = new Thumb($this, $href, $req['type']);
$thumbs[$path] = new Thumb($this, $path, $req['type']);
}
else if ($thumbs[$href]->type === 'file') {
else if ($thumbs[$path]->type === 'file') {
// File has already been mime tested and cannot have a thumbnail
$hrefs[] = null;
continue;
}
$hrefs[] = $thumbs[$href]->thumb($this->thumbnail_width, $this->thumbnail_height);
$hrefs[] = $thumbs[$path]->thumb($this->thumbnail_width, $this->thumbnail_height);
}
return $hrefs;
}
Expand Down

0 comments on commit 435d7f5

Please sign in to comment.