chore(invocation): clean up left-over (and unneeded) conversion of prf

This commit is contained in:
Steve Moyer
2024-11-05 15:28:31 -05:00
parent 728696f169
commit a1aaf47d7c

View File

@@ -231,19 +231,13 @@ func (t *Token) toIPLD(privKey crypto.PrivKey) (datamodel.Node, error) {
Values: t.arguments,
}
// TODO: reuse instead of copy? it's immutable
prf := make([]cid.Cid, len(t.proof))
for i, c := range t.proof {
prf[i] = c
}
model := &tokenPayloadModel{
Iss: t.issuer.String(),
Aud: aud,
Sub: t.subject.String(),
Cmd: t.command.String(),
Args: args,
Prf: prf,
Prf: t.proof,
Meta: t.meta,
Nonce: t.nonce,
Exp: exp,