fixed comments
Olivier Gagnon
8 years ago
46 | 46 | } |
47 | 47 | |
48 | 48 | // We want json.Marshaler and encoding.TextMarshaller to take priority over |
49 | // err.Error() and v.String(). So we force a no-op if it's one of those 2 | |
50 | // case. | |
49 | // err.Error() and v.String(). But json.Marshall (called later) does that by | |
50 | // default so we force a no-op if it's one of those 2 case. | |
51 | 51 | switch x := v.(type) { |
52 | 52 | case json.Marshaler: |
53 | 53 | case encoding.TextMarshaler: |