ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.
()
| 6486 | // ID returns the ID value in the mutation. Note that the ID is only available |
| 6487 | // if it was provided to the builder or after it was returned from the database. |
| 6488 | func (m *MetadataMutation) ID() (id int, exists bool) { |
| 6489 | if m.id == nil { |
| 6490 | return |
| 6491 | } |
| 6492 | return *m.id, true |
| 6493 | } |
| 6494 | |
| 6495 | // IDs queries the database and returns the entity ids that match the mutation's predicate. |
| 6496 | // That means, if the mutation is applied within a transaction with an isolation level such |