mirror of
https://github.com/featurebasedb/featurebase.git
synced 2026-09-07 09:05:55 +00:00
fix test
This commit is contained in:
parent
22bac56dc5
commit
292302f60b
1 changed files with 5 additions and 1 deletions
|
|
@ -778,6 +778,7 @@ func (e *Executor) executeSetProfileAttrs(ctx context.Context, db string, c *pql
|
|||
return ErrDatabaseNotFound
|
||||
}
|
||||
|
||||
var colName string
|
||||
id, ok := c.Args["id"].(uint64)
|
||||
if !ok {
|
||||
// Retrieve columnLabel
|
||||
|
|
@ -787,11 +788,14 @@ func (e *Executor) executeSetProfileAttrs(ctx context.Context, db string, c *pql
|
|||
return errors.New("SetProfileAttrs() id required")
|
||||
}
|
||||
id = col
|
||||
colName = columnLabel
|
||||
} else {
|
||||
colName = "id"
|
||||
}
|
||||
|
||||
// Copy args and remove reserved fields.
|
||||
attrs := pql.CopyArgs(c.Args)
|
||||
delete(attrs, "id")
|
||||
delete(attrs, colName)
|
||||
|
||||
// Set attributes.
|
||||
if err := d.ProfileAttrStore().SetAttrs(id, attrs); err != nil {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue