Fixes to PR #682

- Rename 'playInVlc' preference to 'openExternalPlayer' since we
support more than just VLC now.
- Add default pref options to state.js
This commit is contained in:
Feross Aboukhadijeh
2016-08-20 01:19:50 -07:00
parent 667a04a41d
commit 2d3673ea33
5 changed files with 37 additions and 23 deletions

View File

@@ -29,6 +29,10 @@ function run (state) {
migrate_0_11_0(state.saved)
}
if (semver.lt(version, '0.12.0')) {
migrate_0_12_0(state.saved)
}
// Config is now on the new version
state.saved.version = config.APP_VERSION
}
@@ -104,3 +108,10 @@ function migrate_0_11_0 (saved) {
saved.prefs.isFileHandler = true
}
}
function migrate_0_12_0 (saved) {
if (saved.prefs.openExternalPlayer == null && saved.prefs.playInVlc != null) {
saved.prefs.openExternalPlayer = saved.prefs.playInVlc
}
delete saved.prefs.playInVlc
}