Skip to content
This repository was archived by the owner on Mar 31, 2025. It is now read-only.

atomic record update without sql#11

Open
Jan-Hettich wants to merge 3 commits intoLasVegasRubyGroup:masterfrom
Jan-Hettich:update_without_sql
Open

atomic record update without sql#11
Jan-Hettich wants to merge 3 commits intoLasVegasRubyGroup:masterfrom
Jan-Hettich:update_without_sql

Conversation

@Jan-Hettich
Copy link
Contributor

Replaced handwritten sql update with call to ActiveRecord update! Replaced problematic method_missing with forwarding methods created through meta-programming (creating accessors on the base class for columns in the extension class).

…liminated method_missing, which was causing an issue, because activerecord itself uses method_missing while copying attributes during update; temporarily got tests passing by implementing title and description methods explicitly in the Topic class; however, this will be replaced in future by meta-programming to add the methods from the extension class into the base class.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant