Class: ComicVine::Resource::Episode
- Inherits:
-
ComicVine::Resource
- Object
- ComicVine::Resource
- ComicVine::Resource::Episode
- Includes:
- Mongo, Mongoid::Document
- Defined in:
- lib/comicvine/mongo.rb
Overview
Extends Episode to add mongoid functions
Constant Summary
Constants included from Mongo
Instance Method Summary collapse
-
#has_staff_review=(value) ⇒ Object
Accounts for ComicVine’s miss-match return of false if no review exists.
- #has_staff_review? ⇒ true, false
Methods included from Mongo
#_fetch_by_assoc_and_id, #initialize, #save_assoc!
Methods inherited from ComicVine::Resource
Instance Method Details
#has_staff_review=(value) ⇒ Object
Accounts for ComicVine’s miss-match return of false if no review exists. Sets an empty hash
349 350 351 352 353 354 355 |
# File 'lib/comicvine/mongo.rb', line 349 def has_staff_review=(value) if value.nil? || value.kind_of?(FalseClass) self.has_staff_review = {} else super end end |
#has_staff_review? ⇒ true, false
359 360 361 |
# File 'lib/comicvine/mongo.rb', line 359 def has_staff_review? !self.has_staff_review.empty? end |