mirror of
https://github.com/friendica/friendica
synced 2025-04-19 10:30:10 +00:00
Use old error message when storing fails
This commit is contained in:
parent
d83073f2a2
commit
d20cae82ad
2 changed files with 3 additions and 3 deletions
|
@ -175,8 +175,8 @@ class Upload extends \Friendica\BaseModule
|
|||
|
||||
$smallest = Photo::storeWithPreview($image, $owner['uid'], $resource_id, $filename, $filesize, $album, '', $allow_cid, '', '', '');
|
||||
if ($smallest < 0) {
|
||||
$this->return(401, $this->t('Image could not be uploaded'));
|
||||
@unlink($src);
|
||||
$this->logger->warning('Photo::store() failed');
|
||||
$this->return(401, $this->t('Image upload failed.'));
|
||||
}
|
||||
|
||||
$this->logger->info('upload done');
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue