Remove caching verbosely, add cached_cover_url

This commit is contained in:
Leeingnyo
2021-09-06 02:23:02 +09:00
parent c5b6a8b5b9
commit 565a535d22
5 changed files with 5 additions and 34 deletions
-3
View File
@@ -81,8 +81,6 @@ class Entry
def cover_url
return "#{Config.current.base_url}img/icon.png" if @err_msg
cached_cover_url = LRUCache.get "#{@id}:cover_url"
return cached_cover_url if cached_cover_url.is_a? String
unless @book.entry_cover_url_cache
TitleInfo.new @book.dir do |info|
@@ -98,7 +96,6 @@ class Entry
url = File.join Config.current.base_url, info_url
end
end
LRUCache.set generate_cache_entry "#{@id}:cover_url", url
url
end