Used console.error to make the error of ABI mismatch appear in the logs

This commit is contained in:
Madhur Tandon 2019-01-22 22:43:02 +05:30
parent 37b0913563
commit cf7072d37b
1 changed files with 4 additions and 1 deletions

View File

@ -292,7 +292,10 @@ var languagePluginLoader = new Promise((resolve, reject) => {
Module.checkABI = function(ABI_number) {
if (ABI_number !== parseInt('{{ABI}}')) {
throw `ABI numbers differ. Expected {{ABI}}, got ${ABI_number}`;
var ABI_mismatch_exception =
`ABI numbers differ. Expected {{ABI}}, got ${ABI_number}`;
console.error(ABI_mismatch_exception);
throw ABI_mismatch_exception;
}
return true;
};