statamic-rad-pack / runway

Eloquently manage your database models in Statamic.
https://statamic.com/addons/rad-pack/runway
MIT License
112 stars 47 forks source link

`handleInlinePublishForm` makes 'dirty' model attributes for relations. #534

Closed TheBnl closed 3 months ago

TheBnl commented 3 months ago

Line 240: https://github.com/statamic-rad-pack/runway/blob/9ac7f65e4da0866255bd40ebcaf3950369d1fcbd/src/Http/Controllers/CP/ResourceController.php#L240

Sets relations as attributes on a model. This causes the save action to fail because the model tries to store these attributes in the database, so an SQL exception is thrown.

Omitting this method fixes the issue, but it is probably there for a good reason 😉