SaveX calls Save and panics if Save returns an error.
(ctx context.Context)
| 169 | |
| 170 | // SaveX calls Save and panics if Save returns an error. |
| 171 | func (nc *NodeCreate) SaveX(ctx context.Context) *Node { |
| 172 | v, err := nc.Save(ctx) |
| 173 | if err != nil { |
| 174 | panic(err) |
| 175 | } |
| 176 | return v |
| 177 | } |
| 178 | |
| 179 | // Exec executes the query. |
| 180 | func (nc *NodeCreate) Exec(ctx context.Context) error { |