Fix cloudinary upload error message (#6525)

Signed-off-by: Sudhir Shrestha <sudhirshrestha@live.com>
This commit is contained in:
Sudhir Shrestha 2020-06-24 15:26:02 +07:00 committed by GitHub
parent b2aa657964
commit 0a38ec7bf0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -19,7 +19,8 @@ module.exports = {
{ resource_type: 'auto', public_id: file.hash, ...customConfig },
(err, image) => {
if (err) {
return reject(err);
strapi.log.error(`Error uploading to cloudinary: ${err.message}`);
return reject(new Error('Upload to cloudinary failed'));
}
if (image.resource_type === 'video') {