forked from TrueCloudLab/frostfs-node
f76083484b
Morph event structures defined in `pkg/morph/event` should only carry notification values without any additional interpretation. All logical work should be concentrated on app-side. Change `Bind.User` / `Unbind.User` to return byte slice. Change `Bind.Keys` / `Unbind.Keys` to return `[][]byte`. `ParseBind` / `ParseUnbind` don't decode data from now. Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
24 lines
361 B
Go
24 lines
361 B
Go
package neofs
|
|
|
|
import (
|
|
"github.com/nspcc-dev/neo-go/pkg/vm/stackitem"
|
|
"github.com/nspcc-dev/neofs-node/pkg/morph/event"
|
|
)
|
|
|
|
type Unbind struct {
|
|
bindCommon
|
|
}
|
|
|
|
func ParseUnbind(params []stackitem.Item) (event.Event, error) {
|
|
var (
|
|
ev Unbind
|
|
err error
|
|
)
|
|
|
|
err = parseBind(&ev.bindCommon, params)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
|
|
return ev, nil
|
|
}
|