Fix for golint ./...

pull/34/head
178inaba 2017-04-20 21:20:40 +09:00
parent c417db5189
commit 68843f4dd0
4 changed files with 6 additions and 5 deletions

View File

@ -13,6 +13,7 @@ import (
"github.com/urfave/cli"
)
// SimpleJSON is a struct for output JSON for data to be simple used
type SimpleJSON struct {
ID int64 `json:"id"`
Username string `json:"username"`

View File

@ -26,7 +26,7 @@ func (c *Client) GetNotifications(ctx context.Context) ([]*Notification, error)
return notifications, nil
}
// GetNotifications return notification.
// GetNotification return notification.
func (c *Client) GetNotification(ctx context.Context, id int64) (*Notification, error) {
var notification Notification
err := c.doAPI(ctx, http.MethodGet, fmt.Sprintf("/api/v1/notifications/%d", id), nil, &notification, nil)

View File

@ -23,10 +23,10 @@ func (c *Client) GetReports(ctx context.Context) ([]*Report, error) {
return reports, nil
}
// Report reports the report
func (c *Client) Report(ctx context.Context, accountId int64, ids []int64, comment string) (*Report, error) {
// Report reports the report
func (c *Client) Report(ctx context.Context, accountID int64, ids []int64, comment string) (*Report, error) {
params := url.Values{}
params.Set("account_id", fmt.Sprint(accountId))
params.Set("account_id", fmt.Sprint(accountID))
for _, id := range ids {
params.Add("status_ids[]", fmt.Sprint(id))
}

View File

@ -202,7 +202,7 @@ func (c *Client) Search(ctx context.Context, q string, resolve bool) (*Results,
return &results, nil
}
// PostMedia upload a media attachment.
// UploadMedia upload a media attachment.
func (c *Client) UploadMedia(ctx context.Context, file string) (*Attachment, error) {
var attachment Attachment
err := c.doAPI(ctx, http.MethodPost, "/api/v1/media", file, &attachment, nil)