You've already forked joplin
mirror of
https://github.com/laurent22/joplin.git
synced 2025-12-02 22:49:09 +02:00
All: Fixed sync issue and database migration issue
This commit is contained in:
@@ -205,7 +205,9 @@ class JoplinDatabase extends Database {
|
||||
const existingDatabaseVersions = [0, 1, 2, 3, 4, 5, 6, 7];
|
||||
|
||||
let currentVersionIndex = existingDatabaseVersions.indexOf(fromVersion);
|
||||
if (currentVersionIndex == existingDatabaseVersions.length - 1) return false;
|
||||
// currentVersionIndex < 0 if for the case where an old version of Joplin used with a newer
|
||||
// version of the database, so that migration is not run in this case.
|
||||
if (currentVersionIndex == existingDatabaseVersions.length - 1 || currentVersionIndex < 0) return false;
|
||||
|
||||
while (currentVersionIndex < existingDatabaseVersions.length - 1) {
|
||||
const targetVersion = existingDatabaseVersions[currentVersionIndex + 1];
|
||||
|
||||
Reference in New Issue
Block a user