remove support for extra fields in events -- was deprecated.

This commit is contained in:
fiatjaf
2024-12-28 14:19:28 -03:00
parent 053b3afee7
commit 91efcb3825
4 changed files with 2 additions and 82 deletions

View File

@@ -22,7 +22,6 @@ func easyjsonF642ad3eDecodeGithubComNbdWtfGoNostr(in *jlexer.Lexer, out *Event)
in.Skip()
return
}
out.extra = make(map[string]any)
in.Delim('{')
for !in.IsDelim('}') {
key := in.UnsafeFieldName(true)
@@ -85,8 +84,6 @@ func easyjsonF642ad3eDecodeGithubComNbdWtfGoNostr(in *jlexer.Lexer, out *Event)
out.Content = in.String()
case "sig":
out.Sig = in.String()
default:
out.extra[key] = in.Interface()
}
in.WantComma()
}
@@ -155,12 +152,6 @@ func easyjsonF642ad3eEncodeGithubComNbdWtfGoNostr(out *jwriter.Writer, in Event)
out.String(in.Sig)
}
}
{
for key, value := range in.extra {
out.RawString(",\"" + key + "\":")
out.Raw(json.Marshal(value))
}
}
out.RawByte('}')
}