MCPcopy Create free account
hub / github.com/cloudreve/cloudreve / Exec

Method Exec

ent/node_delete.go:71–81  ·  view source on GitHub ↗

Exec executes the deletion query.

(ctx context.Context)

Source from the content-addressed store, hash-verified

69
70// Exec executes the deletion query.
71func (ndo *NodeDeleteOne) Exec(ctx context.Context) error {
72 n, err := ndo.nd.Exec(ctx)
73 switch {
74 case err != nil:
75 return err
76 case n == 0:
77 return &NotFoundError{node.Label}
78 default:
79 return nil
80 }
81}
82
83// ExecX is like Exec, but panics if an error occurs.
84func (ndo *NodeDeleteOne) ExecX(ctx context.Context) {

Callers 1

ExecXMethod · 0.95

Calls 1

ExecMethod · 0.65

Tested by

no test coverage detected