             }
         }
         sync()
-    }
-    
-    private func countOfAllReadingLists() throws -> Int {
-        assert(Thread.isMainThread)
-        let moc = dataStore.viewContext
-        let request: NSFetchRequest<ReadingList> = ReadingList.fetchRequest()
-        request.predicate = NSPredicate(format: "isDeletedLocally == NO")
-        return try moc.count(for: request)
     }
     
     /// Marks that reading lists were deleted locally and updates associated objects. Doesn't delete them from the NSManagedObjectContext - that should happen only with confirmation from the server that they were deleted.

        }
        
        let listLimit = moc.wmf_readingListsConfigMaxListsPerUser
        let readingListsCount = try countOfAllReadingLists()
        guard readingListsCount + 1 <= listLimit else {
            throw ReadingListError.listLimitReached(limit: listLimit)
        }

            }
        }
    }
    
    func countOfAllReadingLists() throws -> Int {
        assert(Thread.isMainThread)
        let request: NSFetchRequest<ReadingList> = ReadingList.fetchRequest()
        request.predicate = NSPredicate(format: "isDeletedLocally == NO")
        return try self.count(for: request)
    }
}
