edge/pkg/storage/driver/rpc/server/share/delete_attributes.go

29 lines
605 B
Go
Raw Normal View History

package share
import (
"context"
"forge.cadoles.com/arcad/edge/pkg/app"
"forge.cadoles.com/arcad/edge/pkg/storage/share"
"github.com/pkg/errors"
)
type DeleteAttributesArgs struct {
Origin app.ID
ResourceID share.ResourceID
Names []string
}
type DeleteAttributesReply struct {
}
func (s *Service) DeleteAttributes(ctx context.Context, args DeleteAttributesArgs, reply *DeleteAttributesReply) error {
if err := s.store.DeleteAttributes(ctx, args.Origin, args.ResourceID, args.Names...); err != nil {
return errors.WithStack(err)
}
*reply = DeleteAttributesReply{}
return nil
}