MCPcopy Create free account
hub / github.com/efectn/go-orm-benchmarks / SaveX

Method SaveX

bench/ent/model_create.go:75–81  ·  view source on GitHub ↗

SaveX calls Save and panics if Save returns an error.

(ctx context.Context)

Source from the content-addressed store, hash-verified

73
74// SaveX calls Save and panics if Save returns an error.
75func (mc *ModelCreate) SaveX(ctx context.Context) *Model {
76 v, err := mc.Save(ctx)
77 if err != nil {
78 panic(err)
79 }
80 return v
81}
82
83// Exec executes the query.
84func (mc *ModelCreate) Exec(ctx context.Context) error {

Callers

nothing calls this directly

Calls 1

SaveMethod · 0.95

Tested by

no test coverage detected