Save executes the query and returns the updated Node entity.
(ctx context.Context)
| 601 | |
| 602 | // Save executes the query and returns the updated Node entity. |
| 603 | func (nuo *NodeUpdateOne) Save(ctx context.Context) (*Node, error) { |
| 604 | if err := nuo.defaults(); err != nil { |
| 605 | return nil, err |
| 606 | } |
| 607 | return withHooks(ctx, nuo.sqlSave, nuo.mutation, nuo.hooks) |
| 608 | } |
| 609 | |
| 610 | // SaveX is like Save, but panics if an error occurs. |
| 611 | func (nuo *NodeUpdateOne) SaveX(ctx context.Context) *Node { |