This commit is contained in:
2019-10-19 07:49:11 -07:00
parent 6edb46cc86
commit 4c161b0526
6 changed files with 31 additions and 18 deletions

View File

@@ -461,8 +461,6 @@ foreach ($files as $splFileInfo) {
if ($p['thumbs'] || $p['icons'] || $p['meta'] || $p['hash'] || $p['contents'] || $p['spotlight']) {
$parts = array();
$parts[] = $bin_php;
$parts[] = escapeshellarg(realpath("helper.php"));
@@ -765,18 +763,8 @@ foreach ($files as $splFileInfo) {
// Pool
if ($type == "dir") {
if ($type == "file") {
unset($fetch_icon);
$fetch_icon = @$dbp->query("SELECT * FROM icons WHERE fid='".$pid."'")->fetch();
if (@$fetch_icon['relative_path']) {
$stmt->BindValue(":icon_filename",$fetch_icon['relative_path']);
$stmt->BindValue(":icon_tool",$fetch_icon['tool']);
}
} elseif ($type == "file") {
$fetch_icon = @$dbp->query("SELECT * FROM icons WHERE fid='".$fid."'")->fetch();
if (@$fetch_icon['relative_path']) {
$stmt->BindValue(":icon_filename",$fetch_icon['relative_path']);
@@ -808,6 +796,27 @@ foreach ($files as $splFileInfo) {
$stmt->BindValue(":thumb_filename",null);
}
} else {
unset($fetch_icon, $fetch_thumb);
$fetch_icon = @$dbp->query("SELECT * FROM icons WHERE fid='".$pid."'")->fetch();
if (@$fetch_icon['relative_path']) {
$stmt->BindValue(":icon_filename",$fetch_icon['relative_path']);
$stmt->BindValue(":icon_tool",$fetch_icon['tool']);
}
$fetch_thumb = $dbp->query("SELECT * FROM thumbs WHERE fid='".$pid."'")->fetch();
if (@$fetch_thumb['relative_path']) {
$stmt->BindValue(":thumb_filename",$fetch_thumb['relative_path']);
$stmt->BindValue(":thumb_width",$fetch_thumb['width']);
$stmt->BindValue(":thumb_height",$fetch_thumb['height']);
$stmt->BindValue(":thumb_tool",$fetch_thumb['tool']);
} else {
$stmt->BindValue(":thumb_filename",null);
}
}
// ------------------------------------------------ //