ish_models 0.0.33.76 → 0.0.33.77

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/newsitem.rb +1 -1
  3. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: deeec6fc835a3c8501c2b2441ae52be690fc05f9
4
- data.tar.gz: a5ca96a086af904a497f264181d868e48cf68070
3
+ metadata.gz: 8859f35c2cb4c3a879d73d08c50bd5557fbcf859
4
+ data.tar.gz: 90d7472bdd3237130d5b4de3d92e748b92e214bf
5
5
  SHA512:
6
- metadata.gz: f9332c01b89e1df6d74d85ad8452cd42ca3e36db82521b9451553246158b0622ec6ef26007f19208fc0c6f27c55d5d8c32d9690e2eaa59838df152584e2befbd
7
- data.tar.gz: d5cea6d952ed121551506aa9b210a07d041b48a8296cf17ef48a2c97aa2efdd8fa7d54808f2f5537f8e4919a6280e79dc3c460308c3ee585c204fc40551b4fdd
6
+ metadata.gz: eb0a911a30bef4bbf0d97baf8f28726175282fd9f2f984475eeae411641b26c65c5bfa8d95bf4874707e15d5ec7f5695cac2b48cef9f400cb0c117b6679936ad
7
+ data.tar.gz: ce2f4d5792157f0744fa07d973a70a291ac3e677f5b70426dd75d87eeb64a1958f3cdb23a5c17122d82f4d7c612138c537616cdff6db3bdeb9465195423ac22d
data/lib/newsitem.rb CHANGED
@@ -9,7 +9,7 @@ class Newsitem
9
9
 
10
10
  belongs_to :gallery, :optional => true
11
11
  def gallery
12
- Gallery.unscoped.find( self.gallery_id )
12
+ self.gallery_id ? Gallery.unscoped.find( self.gallery_id ) : nil
13
13
  end
14
14
 
15
15
  belongs_to :video, :optional => true
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ish_models
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.33.76
4
+ version: 0.0.33.77
5
5
  platform: ruby
6
6
  authors:
7
7
  - piousbox