From 3f73591dd44fbd705de2cc9bd4b936fa3d16ddf8 Mon Sep 17 00:00:00 2001 From: Alex Ling Date: Sat, 18 Sep 2021 02:14:22 +0000 Subject: [PATCH] Update comments --- src/library/title.cr | 6 +++--- src/storage.cr | 7 ++++--- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/src/library/title.cr b/src/library/title.cr index 853ed1c..1709e9b 100644 --- a/src/library/title.cr +++ b/src/library/title.cr @@ -72,12 +72,12 @@ class Title # Utility method used in library rescanning. # - When the title does not exist on the file system anymore, return false - # and let it be deleted from the libaray instance - # - When the title exists, but its contents sigature is now different from + # and let it be deleted from the library instance + # - When the title exists, but its contents signature is now different from # the cache, it means some of its content (nested titles or entries) # has been added, deleted, or renamed. In this case we update its # contents signature and instance variables - # - When the title exists and its contents sigature is still the same, we + # - When the title exists and its contents signature is still the same, we # return true so it can be reused without rescanning def examine(context : ExamineContext) : Bool return false unless Dir.exists? @dir # No title, Remove this diff --git a/src/storage.cr b/src/storage.cr index 762946d..eea5927 100644 --- a/src/storage.cr +++ b/src/storage.cr @@ -428,9 +428,10 @@ class Storage end end - # Limit mark targets with given arguments - # They should be checked again if they are really gone, - # since they would be available which are renamed or moved + # Mark titles and entries that no longer exist on the file system as + # unavailable. By supplying `id_candidates` and `titles_candidates`, it + # only checks the existence of the candidate titles/entries to speed up + # the process. def mark_unavailable(ids_candidates : Array(String)?, titles_candidates : Array(String)?) MainFiber.run do