Why Nostr? What is Njump?
2025-03-31 15:53:38
in reply to

mleku on Nostr: if err = okenvelope.NewFrom(env.Id, false, normalize.AuthRequired.F("auth required ...

if err = okenvelope.NewFrom(env.Id, false,
normalize.AuthRequired.F("auth required for storing events")).Write(ws); chk.T(err) {
}


and that normalize function:


func (r Reason) F(format string, params ...any) []byte { return Msg(r, format, params...) }

you see, Msg:

// Msg constructs a properly formatted message with a machine-readable prefix for OK and CLOSED
// envelopes.
func Msg(prefix Reason, format string, params ...any) []byte {
if len(prefix) < 1 {
prefix = Error
}
return []byte(fmt.Sprintf(prefix.S()+": "+format, params...))
}

Author Public Key
npub1fjqqy4a93z5zsjwsfxqhc2764kvykfdyttvldkkkdera8dr78vhsmmleku