mirror of
https://github.com/hkalexling/Mango.git
synced 2026-01-25 00:00:36 -05:00
Entry selector on reader page (closes #168)
This commit is contained in:
@@ -134,10 +134,11 @@ class Entry
|
||||
entries[idx + 1]
|
||||
end
|
||||
|
||||
def previous_entry
|
||||
idx = @book.entries.index self
|
||||
def previous_entry(username)
|
||||
entries = @book.sorted_entries username
|
||||
idx = entries.index self
|
||||
return nil if idx.nil? || idx == 0
|
||||
@book.entries[idx - 1]
|
||||
entries[idx - 1]
|
||||
end
|
||||
|
||||
def date_added
|
||||
|
||||
Reference in New Issue
Block a user