Skip to content

Commit

Permalink
Fixes S3 media items in bucket root folders (octobercms#3461)
Browse files Browse the repository at this point in the history
FIxes octobercms#3445. Credit to @rajakhoury
  • Loading branch information
rajakhoury authored and LukeTowers committed Mar 20, 2018
1 parent 6104520 commit d977ba5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion modules/system/classes/MediaLibrary.php
Original file line number Diff line number Diff line change
Expand Up @@ -574,7 +574,7 @@ protected function initLibraryItem($path, $itemType)
? $this->getStorageDisk()->size($path)
: $this->getFolderItemCount($path);

$publicUrl = $this->storagePath.$relativePath;
$publicUrl = $this->getPathUrl($relativePath);

return new MediaLibraryItem($relativePath, $size, $lastModified, $itemType, $publicUrl);
}
Expand Down

0 comments on commit d977ba5

Please sign in to comment.