Skip to content

Commit a5f533b

Browse files
committed
investigating broken collection.loading? method
1 parent 29cac13 commit a5f533b

File tree

1 file changed

+8
-3
lines changed
  • ruby/hyper-model/lib/reactive_record/active_record/reactive_record

1 file changed

+8
-3
lines changed

ruby/hyper-model/lib/reactive_record/active_record/reactive_record/collection.rb

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -587,9 +587,14 @@ def loading?
587587
@dummy_collection.loading?
588588
end
589589

590-
def loaded?
591-
false && @collection && (!@dummy_collection || !@dummy_collection.loading?) && (!@owner || @owner.id || @vector.length > 1)
592-
end
590+
# def loading?
591+
# !@collection || (@dummy_collection && @dummy_collection.loading?) || (@owner && [email protected] && @vector && @vector.length <= 1)
592+
# end
593+
594+
# def loaded?
595+
# @collection && (!@dummy_collection || !@dummy_collection.loading?) && (!@owner || @owner.id || !@vector || @vector.length > 1)
596+
# #false && @collection && (!@dummy_collection || !@dummy_collection.loading?) && (!@owner || @owner.id || @vector.length > 1)
597+
# end
593598

594599
def empty?
595600
# should be handled by method missing below, but opal-rspec does not deal well

0 commit comments

Comments
 (0)