Skip to content

Commit

Permalink
Only show released Books
Browse files Browse the repository at this point in the history
  • Loading branch information
dsomel21 committed Feb 16, 2024
1 parent 0c53573 commit 64ca719
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/models/book.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ class Book < ApplicationRecord
# @example `@books = Book.released`
# @return [ActiveRecord::Relation] Set of released Books.
if Rails.env.production?
scope :released, -> { all }
else
scope :released, -> { where.not(:en_short_summary => nil) }
else
scope :released, -> { all }
end

def last_chapter
Expand Down

0 comments on commit 64ca719

Please sign in to comment.