Skip to content

Commit

Permalink
Fixes tests for Ruby 2.2
Browse files Browse the repository at this point in the history
  • Loading branch information
zedtux committed Sep 10, 2021
1 parent 009c340 commit df8bc0e
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/no_brainer/document/association/belongs_to.rb
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,9 @@ def target_model(target_class = nil)
end

def base_criteria(target_class = nil)
target_model(target_class)&.without_ordering
model = target_model(target_class)

model ? model.without_ordering : nil
end

def hook
Expand Down

0 comments on commit df8bc0e

Please sign in to comment.