diff --git a/src/core/services/sites.ts b/src/core/services/sites.ts index e6538fd4e..032ebcf23 100644 --- a/src/core/services/sites.ts +++ b/src/core/services/sites.ts @@ -262,7 +262,7 @@ export class CoreSitesProvider { } // Service supported but an error happened. Return error. - if (error.errorcode == 'codingerror') { + if (error.errorcode === 'codingerror') { // This could be caused by a redirect. Check if it's the case. const redirect = await CoreUtils.checkRedirect(siteUrl); @@ -272,6 +272,9 @@ export class CoreSitesProvider { // We can't be sure if there is a redirect or not. Display cannot connect error. error.message = Translate.instant('core.cannotconnecttrouble'); } + } else if (error.errorcode === 'invalidrecord') { + // WebService not found, site not supported. + error.message = Translate.instant('core.login.invalidmoodleversion', { $a: CoreSite.MINIMUM_MOODLE_VERSION }); } return new CoreSiteError({