liveh2o / active_remote

Active Remote provides Active Record-like object-relational mapping over RPC. It's Active Record for your platform.
MIT License
63 stars 23 forks source link

Adds writer method for has_many associations #51

Closed fergmastaflex closed 7 years ago

fergmastaflex commented 7 years ago

This also adds a check to see if the new value in the setter is an array because duh.

Part of https://github.com/liveh2o/active_remote/issues/45

@liveh2o

fergmastaflex commented 7 years ago

I do! If you attempt to add a single record to a collection using a writer method, you get this:

NoMethodError: undefined method `each' for #<Comment id: nil, body: nil,
admin_post_id: nil>

The error in active remote is actually more explicit.

liveh2o commented 7 years ago

We've started work on v3.0 in master. If you want to wait until that is done for this to be released, cool. Otherwise, you can close this, rebase from the 2-4-stable branch, and reopen against that branch. Up to you.

fergmastaflex commented 7 years ago

Sorry for the delayed response. I'm down to wait. NBD.

liveh2o commented 7 years ago

Cool. Merging into master.