diff options
author | Thiago Marcos P. Santos <tmpsantos@gmail.com> | 2017-08-21 17:58:27 +0300 |
---|---|---|
committer | Thiago Marcos P. Santos <tmpsantos@gmail.com> | 2017-08-22 12:46:38 +0300 |
commit | 558d4b1a88c5b8367a073fc428b2843f28555d96 (patch) | |
tree | ac2f7f350e1985124c7018e559300fca679ac290 | |
parent | 224e9e6261e332dc97b3fad3be58f3146d07b280 (diff) | |
download | qtlocation-mapboxgl-558d4b1a88c5b8367a073fc428b2843f28555d96.tar.gz |
[core] Remove database on schema downgrade
Previously we were throwing an exception.
-rw-r--r-- | platform/default/mbgl/storage/offline_database.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/platform/default/mbgl/storage/offline_database.cpp b/platform/default/mbgl/storage/offline_database.cpp index d38f0c9108..65c2097182 100644 --- a/platform/default/mbgl/storage/offline_database.cpp +++ b/platform/default/mbgl/storage/offline_database.cpp @@ -51,7 +51,7 @@ void OfflineDatabase::ensureSchema() { case 4: migrateToVersion5(); // fall through case 5: migrateToVersion6(); // fall through case 6: return; - default: throw std::runtime_error("unknown schema version"); + default: break; // downgrade, delete the database } removeExisting(); |