Fixed: get path url from storage rather from http
This commit is contained in:
parent
6c5d21ec44
commit
b4c8125d72
|
@ -1,5 +1,6 @@
|
||||||
<?php namespace Aweos\Resizer;
|
<?php namespace Aweos\Resizer;
|
||||||
|
|
||||||
|
use Storage;
|
||||||
use Backend;
|
use Backend;
|
||||||
use System\Classes\PluginBase;
|
use System\Classes\PluginBase;
|
||||||
use System\Classes\MediaLibrary;
|
use System\Classes\MediaLibrary;
|
||||||
|
@ -153,7 +154,7 @@ class Plugin extends PluginBase
|
||||||
return false;
|
return false;
|
||||||
})
|
})
|
||||||
->map(function($fileVersion) use ($l) {
|
->map(function($fileVersion) use ($l) {
|
||||||
$sizes = getimagesize($l->getPathUrl($fileVersion->path));
|
$sizes = getimagesize(Storage::path('media/'.$fileVersion->path));
|
||||||
|
|
||||||
return [$l->getPathUrl($fileVersion->path), $sizes[0], $sizes[1]];
|
return [$l->getPathUrl($fileVersion->path), $sizes[0], $sizes[1]];
|
||||||
})->sortBy(function($size) {
|
})->sortBy(function($size) {
|
||||||
|
|
Loading…
Reference in New Issue