Utilities for a JSON-based API.
選択できるのは25トピックまでです。
トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。
|
- package impart
-
- import (
- "net/http"
- )
-
- type HTTPError struct {
- Status int
- Message string
- }
-
- func (h HTTPError) Error() string {
- if h.Message == "" {
- return http.StatusText(h.Status)
- }
- return h.Message
- }
|