SaveX is like Save, but panics if an error occurs.
(ctx context.Context)
| 170 | |
| 171 | // SaveX is like Save, but panics if an error occurs. |
| 172 | func (tu *TaskUpdate) SaveX(ctx context.Context) int { |
| 173 | affected, err := tu.Save(ctx) |
| 174 | if err != nil { |
| 175 | panic(err) |
| 176 | } |
| 177 | return affected |
| 178 | } |
| 179 | |
| 180 | // Exec executes the query. |
| 181 | func (tu *TaskUpdate) Exec(ctx context.Context) error { |