Fix annotation from review

This commit is contained in:
Art4 2024-11-18 14:20:57 +00:00
parent 817eeb9734
commit ae52648950
3 changed files with 4 additions and 2 deletions

View file

@ -167,7 +167,7 @@ class Display extends BaseModule
{
$author = [];
$shared = $this->contentItem->getSharedPost($item, ['author-link']);
if (array_key_exists('comment', $shared) && !$shared['comment']) {
if (array_key_exists('comment', $shared) && strval($shared['comment']) !== '') {
$author = Contact::getByURLForUser($shared['post']['author-link'], $this->session->getLocalUserId());
}

View file

@ -78,7 +78,6 @@ class Magic extends BaseModule
$contact = Contact::getByURL($addr ?: $dest);
if ($contact === [] && $owa === 0) {
# code...
$this->logger->info('No contact record found, no oWA, redirecting to destination.', ['request' => $request, 'server' => $_SERVER, 'dest' => $dest]);
$this->app->redirect($dest);
}

View file

@ -182,6 +182,9 @@ class Crop extends BaseSettings
}
$Image = Photo::getImageForPhoto($photos[0]);
if (!$Image->isValid()) {
throw new HTTPException\InternalServerErrorException();
}
$imagecrop = [
'resource-id' => $resource_id,