李伟乐 2 years ago
parent b0aad85f2b
commit 4ff4b3551d
  1. 2
      encoding/encoding.go

@ -1,6 +1,7 @@
package encoding package encoding
import ( import (
"fmt"
"strings" "strings"
) )
@ -30,6 +31,7 @@ func RegisterCodec(codec Codec) {
panic("cannot register Codec with empty string result for Name()") panic("cannot register Codec with empty string result for Name()")
} }
contentSubtype := strings.ToLower(codec.Name()) contentSubtype := strings.ToLower(codec.Name())
fmt.Println("reg", contentSubtype)
registeredCodecs[contentSubtype] = codec registeredCodecs[contentSubtype] = codec
} }

Loading…
Cancel
Save