No need to pass $before and $after values for determining permissions
This commit is contained in:
parent
cca75c70fc
commit
ddf87a7188
1 changed files with 0 additions and 8 deletions
|
@ -74,16 +74,8 @@ func (d *document) perms(ctx context.Context, doc *data.Doc) (err error) {
|
|||
|
||||
if p, ok := fd.Perms.(*sql.PermExpression); ok {
|
||||
|
||||
// Get the old value
|
||||
|
||||
old := d.initial.Get(key).Data()
|
||||
|
||||
// Reset the variables
|
||||
|
||||
vars := data.New()
|
||||
vars.Set(val, varKeyValue)
|
||||
vars.Set(val, varKeyAfter)
|
||||
vars.Set(old, varKeyBefore)
|
||||
ctx = context.WithValue(ctx, ctxKeySpec, vars)
|
||||
|
||||
if v, err := d.i.e.fetch(ctx, p.Select, doc); err != nil {
|
||||
|
|
Loading…
Reference in a new issue