Skip to content

Commit 696c5cb

Browse files
Merge pull request #2 from casderooij/master
Get file directory for listed pages
2 parents fd4ce9b + 5514a09 commit 696c5cb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/Convert.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ public function generateWebP($file)
3131
// Checking file type since only images are processed
3232
if ($file->type() == 'image') {
3333
// WebPConvert options
34-
$path = kirby()->root('content') . '/' . dirname($file->id()) . '/';
34+
$path = $file->contentFileDirectory() . '/';
3535
$input = $path . $file->filename();
3636
$output = $path . $file->name() . '.webp';
3737

0 commit comments

Comments
 (0)