newMembershipMutation creates new mutation for the Membership entity.
(c config, op Op, opts ...membershipOption)
| 7040 | |
| 7041 | // newMembershipMutation creates new mutation for the Membership entity. |
| 7042 | func newMembershipMutation(c config, op Op, opts ...membershipOption) *MembershipMutation { |
| 7043 | m := &MembershipMutation{ |
| 7044 | config: c, |
| 7045 | op: op, |
| 7046 | typ: TypeMembership, |
| 7047 | clearedFields: make(map[string]struct{}), |
| 7048 | } |
| 7049 | for _, opt := range opts { |
| 7050 | opt(m) |
| 7051 | } |
| 7052 | return m |
| 7053 | } |
| 7054 | |
| 7055 | // withMembershipID sets the ID field of the mutation. |
| 7056 | func withMembershipID(id uuid.UUID) membershipOption { |
no outgoing calls
no test coverage detected