method

save_belongs_to_association

rails latest stable - Class: ActiveRecord::AutosaveAssociation
save_belongs_to_association(reflection)
private

Saves the associated record if it’s new or :autosave is enabled.

In addition, it will destroy the association if it was marked for destruction.