mirror of
https://github.com/status-im/realm-js.git
synced 2025-01-10 14:25:58 +00:00
Pr review
This commit is contained in:
parent
f2030cae06
commit
f4d32eba06
@ -21,7 +21,7 @@ X.Y.Z-rc Release notes
|
||||
* Upgrading to Realm Core 4.0.0 and Realm Sync 2.0.0-rc25.
|
||||
|
||||
### Enhancements
|
||||
** Support Realm migration from sync 1.0 to sync 2.0 version
|
||||
* None
|
||||
|
||||
### Bug fixes
|
||||
* Configuration of sync file system is not done on module import but later when actually needed by sync (#1351)
|
||||
|
@ -246,14 +246,14 @@ function sendRequest(command, data, host = sessionHost) {
|
||||
if (error && error.replace) {
|
||||
error = error.replace(/^[a-z]+: /i, '');
|
||||
}
|
||||
else if (error.type && error.type == 'dict') {
|
||||
else if (error.type && error.type === 'dict') {
|
||||
const responseError = deserialize_json_value(error);
|
||||
let responeMessage;
|
||||
if (response.message && response.message !== '') {
|
||||
// Remove the type prefix from the error message (e.g. "Error: ").
|
||||
responeMessage = response.message.replace(/^[a-z]+: /i, '');
|
||||
}
|
||||
|
||||
|
||||
const exceptionToReport = new Error(responeMessage);
|
||||
Object.assign(exceptionToReport, responseError);
|
||||
throw exceptionToReport;
|
||||
|
Loading…
x
Reference in New Issue
Block a user