fix CLOSED->CLOSE marshaling on CloseEnvelope.

This commit is contained in:
fiatjaf
2023-12-01 12:57:18 -03:00
parent 3adb1cde3c
commit 775821f4e5

View File

@ -257,7 +257,7 @@ func (v *CloseEnvelope) UnmarshalJSON(data []byte) error {
func (v CloseEnvelope) MarshalJSON() ([]byte, error) {
w := jwriter.Writer{}
w.RawString(`["CLOSED",`)
w.RawString(`["CLOSE",`)
w.Raw(json.Marshal(string(v)))
w.RawString(`]`)
return w.BuildBytes()