diff --git a/src/actions/GetImagesAction.php b/src/actions/GetImagesAction.php index 70eef58..0e3d181 100755 --- a/src/actions/GetImagesAction.php +++ b/src/actions/GetImagesAction.php @@ -86,12 +86,11 @@ public function run() $files = []; foreach (FileHelper::findFiles($this->path, $this->options) as $path) { - $file = basename($path); - $url = $this->url . urlencode($file); + $url = $this->url . str_replace($this->path, '', $path) $files[] = [ - 'id' => $file, - 'title' => $file, + 'id' => $url, + 'title' => $url, 'thumb' => $url, 'image' => $url, ];