Fix vetting errors

This commit is contained in:
Fabian Reinartz 2016-02-15 11:18:23 +01:00
parent 3620d996cf
commit 6e82fdd419
4 changed files with 39 additions and 38 deletions

2
api.go
View File

@ -403,7 +403,7 @@ func respondError(w http.ResponseWriter, apiErr apiError, data interface{}) {
case errorInternal:
w.WriteHeader(http.StatusInternalServerError)
default:
panic(fmt.Sprintf("unknown error type", apiErr))
panic(fmt.Sprintf("unknown error type %q", apiErr))
}
b, err := json.Marshal(&response{

View File

@ -607,14 +607,15 @@ type opsGenieMessage struct {
}
type opsGenieCreateMessage struct {
*opsGenieMessage `json:,inline`
*opsGenieMessage `json:",inline"`
Message string `json:"message"`
Details map[string]string `json:"details"`
Source string `json:"source"`
}
type opsGenieCloseMessage struct {
*opsGenieMessage `json:,inline`
*opsGenieMessage `json:",inline"`
}
// Notify implements the Notifier interface.

View File

@ -182,6 +182,7 @@ type bintree struct {
Func func() (*asset, error)
Children map[string]*bintree
}
var _bintree = &bintree{nil, map[string]*bintree{
"template": &bintree{nil, map[string]*bintree{
"default.tmpl": &bintree{templateDefaultTmpl, map[string]*bintree{}},
@ -234,4 +235,3 @@ func _filePath(dir, name string) string {
cannonicalName := strings.Replace(name, "\\", "/", -1)
return filepath.Join(append([]string{dir}, strings.Split(cannonicalName, "/")...)...)
}

View File

@ -578,6 +578,7 @@ type bintree struct {
Func func() (*asset, error)
Children map[string]*bintree
}
var _bintree = &bintree{nil, map[string]*bintree{
"ui": &bintree{nil, map[string]*bintree{
"app": &bintree{nil, map[string]*bintree{
@ -658,4 +659,3 @@ func _filePath(dir, name string) string {
cannonicalName := strings.Replace(name, "\\", "/", -1)
return filepath.Join(append([]string{dir}, strings.Split(cannonicalName, "/")...)...)
}