mirror of
https://github.com/hkalexling/Mango.git
synced 2025-08-02 19:05:32 -04:00
Avoid not_nil in date_added
This commit is contained in:
parent
df618704ea
commit
39a331c879
@ -226,7 +226,7 @@ abstract class Entry
|
||||
end
|
||||
|
||||
def date_added : Time
|
||||
date_added = nil
|
||||
date_added = Time::UNIX_EPOCH
|
||||
TitleInfo.new @book.dir do |info|
|
||||
info_da = info.date_added[@title]?
|
||||
if info_da.nil?
|
||||
@ -236,7 +236,7 @@ abstract class Entry
|
||||
date_added = info_da
|
||||
end
|
||||
end
|
||||
date_added.not_nil! # is it ok to set not_nil! here?
|
||||
date_added
|
||||
end
|
||||
|
||||
# Hack to have abstract class methods
|
||||
|
Loading…
x
Reference in New Issue
Block a user