We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7f7b45d commit dd7f5a6Copy full SHA for dd7f5a6
src/traits/LfmHelpers.php
@@ -96,9 +96,9 @@ private function appendThumbFolderPath($is_thumb)
96
}
97
98
$thumb_folder_name = config('lfm.thumb_folder_name');
99
- //if user is inside thumbs folder there is no need
100
- // to add thumbs substring to the end of $url
101
- $in_thumb_folder = preg_match('/'.$thumb_folder_name.'$/i', $this->getFormatedWorkingDir());
+ // if user is inside thumbs folder, there is no need
+ // to add thumbs substring to the end of url
+ $in_thumb_folder = str_contains($this->getFormatedWorkingDir(), $this->ds . $thumb_folder_name);
102
103
if (!$in_thumb_folder) {
104
return $thumb_folder_name . $this->ds;
0 commit comments