X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;ds=sidebyside;f=src%2FModel%2FPhoto.php;h=e64158e175ced54a67d79fecf190be2965c561b5;hb=0080d117eeb247bbb43b73d40830e7783b46dcde;hp=5400cafb40394be2d35708c8ad1cf7d4e411e68e;hpb=cfa68c52b9117616fa95a4639ad74e7d220d193d;p=friendica.git diff --git a/src/Model/Photo.php b/src/Model/Photo.php index 5400cafb40..e64158e175 100644 --- a/src/Model/Photo.php +++ b/src/Model/Photo.php @@ -146,7 +146,7 @@ class Photo // Remove the cached photo $a = get_app(); - $basepath = $a->get_basepath(); + $basepath = $a->getBasePath(); if (is_dir($basepath . "/photo")) { $filename = $basepath . '/photo/' . $hash . '-4.' . $Image->getExt(); @@ -239,8 +239,8 @@ class Photo WHERE `uid` = %d AND `album` != '%s' AND `album` != '%s' $sql_extra GROUP BY `album` ORDER BY `created` DESC", intval($uid), - dbesc('Contact Photos'), - dbesc(L10n::t('Contact Photos')) + DBA::escape('Contact Photos'), + DBA::escape(L10n::t('Contact Photos')) ); } else { // This query doesn't do the count and is much faster @@ -248,8 +248,8 @@ class Photo FROM `photo` USE INDEX (`uid_album_scale_created`) WHERE `uid` = %d AND `album` != '%s' AND `album` != '%s' $sql_extra", intval($uid), - dbesc('Contact Photos'), - dbesc(L10n::t('Contact Photos')) + DBA::escape('Contact Photos'), + DBA::escape(L10n::t('Contact Photos')) ); } Cache::set($key, $albums, CACHE_DAY);