mirror of
https://github.com/abraunegg/onedrive
synced 2024-06-29 19:02:59 +02:00
Update sync.d
* Update exit codes on sync.init() to -1
This commit is contained in:
parent
cbd3ecbf71
commit
23e79d39e1
|
@ -192,20 +192,20 @@ final class SyncEngine
|
||||||
log.error("ERROR: Check your 'drive_id' entry in your configuration file as it may be incorrect\n");
|
log.error("ERROR: Check your 'drive_id' entry in your configuration file as it may be incorrect\n");
|
||||||
}
|
}
|
||||||
// Must exit here
|
// Must exit here
|
||||||
exit(0);
|
exit(-1);
|
||||||
}
|
}
|
||||||
if (e.httpStatusCode == 401) {
|
if (e.httpStatusCode == 401) {
|
||||||
// HTTP request returned status code 401 (Unauthorized)
|
// HTTP request returned status code 401 (Unauthorized)
|
||||||
log.error("\nERROR: OneDrive returned a 'HTTP 401 Unauthorized' - Cannot Initialize Sync Engine");
|
log.error("\nERROR: OneDrive returned a 'HTTP 401 Unauthorized' - Cannot Initialize Sync Engine");
|
||||||
log.error("ERROR: Check your configuration as your access token may be empty or invalid\n");
|
log.error("ERROR: Check your configuration as your access token may be empty or invalid\n");
|
||||||
// Must exit here
|
// Must exit here
|
||||||
exit(0);
|
exit(-1);
|
||||||
}
|
}
|
||||||
if (e.httpStatusCode >= 500) {
|
if (e.httpStatusCode >= 500) {
|
||||||
// There was a HTTP 5xx Server Side Error
|
// There was a HTTP 5xx Server Side Error
|
||||||
log.error("ERROR: OneDrive returned a 'HTTP 5xx Server Side Error' - Cannot Initialize Sync Engine");
|
log.error("ERROR: OneDrive returned a 'HTTP 5xx Server Side Error' - Cannot Initialize Sync Engine");
|
||||||
// Must exit here
|
// Must exit here
|
||||||
exit(0);
|
exit(-1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue