-
-
Notifications
You must be signed in to change notification settings - Fork 872
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
check config file keys for validity, use setValue instead of direct access #296
Conversation
My recommendation is to include this into 2.2.2 milestone, to fix things like what has happened in #293 |
For some reason this change ignore's this in the config file:
Output with this PR:
Output with master:
Note the switch to the Office 365 Shared Library because 'drive_id' was in the config Also, if
If
|
Ahh. indeed ... because
but that was wrong. How can one find the definitive list of allowed config options? |
Looking right now at this as if |
OK .. that has the desired effect where now 'drive_id' is correctly picked up. I am thinking here as well - if there is a 'config' file issue, we don't allow the application to sync - as, if for example the 'drive_id' is spelt incorrectly, the actual account 'drive_id' would be used - which is what led to #293 |
Add 'drive_id' to be initialised, set to an empty string
* Issue #293 was caused by a spelling error in the configuration file. If the configuration file has errors, we should not load it or run using the application defaults as this may have undesirable consequences for users data
* Missed this edit of the file
I think this is good to merge now - thoughts? |
Thanks, merged! |
For some reason --syncdir option is ignored when starting onedrive with latest master code. This caused all my items to be deleted when docker image was used Message on output showed that it will sync /home/onedrive/OneDrive folder. |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
All possible values are already initialized in
init
before the config file is loaded. Check the keys of the config files against the existing keys and warn in case of mismatch.Furthermore, instead of directly changing the
values
array, use thesetValue
function to allow for easier reimplementation of the configuration storage.