diff --git a/app/src/main/java/com/orgzly/android/sync/BookNamesake.java b/app/src/main/java/com/orgzly/android/sync/BookNamesake.java index c20da5b25..609c74b9c 100644 --- a/app/src/main/java/com/orgzly/android/sync/BookNamesake.java +++ b/app/src/main/java/com/orgzly/android/sync/BookNamesake.java @@ -149,14 +149,19 @@ public void updateStatus(int reposCount) { status = BookSyncStatus.ONLY_BOOK_WITH_LINK; } } else { /* Only local book without link. */ - if (reposCount > 1) { - status = BookSyncStatus.ONLY_BOOK_WITHOUT_LINK_AND_MULTIPLE_REPOS; + if (book.hasSync()) { + // Book has been synced previously, but lost its link. + status = BookSyncStatus.SYNCED_BOOK_WITHOUT_LINK; } else { - status = BookSyncStatus.ONLY_BOOK_WITHOUT_LINK_AND_ONE_REPO; - } // TODO: What about no repos? + // Book has never been synced. + if (reposCount > 1) { + status = BookSyncStatus.ONLY_BOOK_WITHOUT_LINK_AND_MULTIPLE_REPOS; + } else { + status = BookSyncStatus.ONLY_BOOK_WITHOUT_LINK_AND_ONE_REPO; + } // TODO: What about no repos? + } } } - return; }