(ctx context.Context, id db.GraphID)
| 130 | } |
| 131 | |
| 132 | func (d *DB) GraphSalts(ctx context.Context, id db.GraphID) ([]*db.GraphSalt, error) { |
| 133 | gss, err := d.q.GraphSalts(ctx, string(id)) |
| 134 | if errors.Is(err, sql.ErrNoRows) { |
| 135 | return nil, db.NotExists("graph", id) |
| 136 | } else if err != nil { |
| 137 | return nil, fmt.Errorf("failed to load graph salts: %w", err) |
| 138 | } |
| 139 | return convSlice(gss, toGraphSalt), nil |
| 140 | } |
| 141 | |
| 142 | func toGraphSalt(g sqlitedb.GraphSalt) *db.GraphSalt { |
| 143 | return &db.GraphSalt{ |
nothing calls this directly
no test coverage detected