fix minor things

This commit is contained in:
Sergey Dudoladov
2019-01-02 17:45:50 +01:00
parent cba48ea9dd
commit 7b4128d4bc
10 changed files with 23 additions and 21 deletions
+2 -2
View File
@@ -19,7 +19,7 @@ type fieldInfo struct {
Field reflect.Value
}
// StringTemplate is string
// StringTemplate is a convenience alias
type StringTemplate string
func decoderFrom(field reflect.Value) (d decoder) {
@@ -240,7 +240,7 @@ func (f *StringTemplate) Format(a ...string) string {
return res
}
// MarshalJSON returns json.Marshal(byte slice) from StringTemplate
// MarshalJSON converts a StringTemplate to byte slice
func (f StringTemplate) MarshalJSON() ([]byte, error) {
return json.Marshal(string(f))
}
+1 -1
View File
@@ -43,7 +43,7 @@ type httpClient interface {
Do(req *http.Request) (*http.Response, error)
}
// Interface have to implement TeamInfo
// Interface to the TeamsAPIClient
type Interface interface {
TeamInfo(teamID, token string) (tm *Team, err error)
}