Merge pull request #2325 from dpalou/MOBILE-3269

MOBILE-3269 core: Fix error displayed when capturing media
main
Juan Leyva 2020-03-25 10:42:58 +01:00 committed by GitHub
commit 10056908f0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 1 deletions

View File

@ -399,7 +399,10 @@ export class CoreFileUploaderHelperProvider {
// Error, not cancelled.
this.logger.error('Error while recording audio/video', error);
return Promise.reject(this.translate.instant(defaultMessage));
const message = error.code == 20 ? this.translate.instant('core.fileuploader.errornoapp') :
(error.message || this.translate.instant(defaultMessage));
return Promise.reject(message);
} else {
this.logger.debug('Cancelled');
}