Skip to content

Commit

Permalink
Story#public_similar_story: return [] not nil
Browse files Browse the repository at this point in the history
  • Loading branch information
abdallahalsamman authored and pushcx committed Dec 5, 2018
1 parent bac3fe9 commit 3426d6f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/models/story.rb
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ def similar_stories
end

def public_similar_stories
@_public_similar_stories ||= similar_stories.base
@_public_similar_stories ||= similar_stories.empty? ? [] : similar_stories.base
end

def most_recent_similar
Expand Down

0 comments on commit 3426d6f

Please sign in to comment.