Update dependencies (#1929)
This commit is contained in:
2
vendor/github.com/slack-go/slack/dialog_text.go
generated
vendored
2
vendor/github.com/slack-go/slack/dialog_text.go
generated
vendored
@@ -18,7 +18,7 @@ const (
|
||||
)
|
||||
|
||||
// TextInputElement subtype of DialogInput
|
||||
// https://api.slack.com/dialogs#option_element_attributes#text_element_attributes
|
||||
// https://api.slack.com/dialogs#option_element_attributes#text_element_attributes
|
||||
type TextInputElement struct {
|
||||
DialogInput
|
||||
MaxLength int `json:"max_length,omitempty"`
|
||||
|
||||
2
vendor/github.com/slack-go/slack/files.go
generated
vendored
2
vendor/github.com/slack-go/slack/files.go
generated
vendored
@@ -299,7 +299,7 @@ func (api *Client) UploadFile(params FileUploadParameters) (file *File, err erro
|
||||
func (api *Client) UploadFileContext(ctx context.Context, params FileUploadParameters) (file *File, err error) {
|
||||
// Test if user token is valid. This helps because client.Do doesn't like this for some reason. XXX: More
|
||||
// investigation needed, but for now this will do.
|
||||
_, err = api.AuthTest()
|
||||
_, err = api.AuthTestContext(ctx)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
5
vendor/github.com/slack-go/slack/info.go
generated
vendored
5
vendor/github.com/slack-go/slack/info.go
generated
vendored
@@ -409,6 +409,11 @@ func (t JSONTime) Time() time.Time {
|
||||
func (t *JSONTime) UnmarshalJSON(buf []byte) error {
|
||||
s := bytes.Trim(buf, `"`)
|
||||
|
||||
if bytes.EqualFold(s, []byte("null")) {
|
||||
*t = JSONTime(0)
|
||||
return nil
|
||||
}
|
||||
|
||||
v, err := strconv.Atoi(string(s))
|
||||
if err != nil {
|
||||
return err
|
||||
|
||||
2
vendor/github.com/slack-go/slack/internal/backoff/backoff.go
generated
vendored
2
vendor/github.com/slack-go/slack/internal/backoff/backoff.go
generated
vendored
@@ -51,7 +51,7 @@ func (b *Backoff) Duration() (dur time.Duration) {
|
||||
return dur
|
||||
}
|
||||
|
||||
//Resets the current value of the counter back to Min
|
||||
// Resets the current value of the counter back to Min
|
||||
func (b *Backoff) Reset() {
|
||||
b.attempts = 0
|
||||
}
|
||||
|
||||
2
vendor/github.com/slack-go/slack/misc.go
generated
vendored
2
vendor/github.com/slack-go/slack/misc.go
generated
vendored
@@ -50,7 +50,7 @@ type SlackErrorResponse struct {
|
||||
|
||||
func (r SlackErrorResponse) Error() string { return r.Err }
|
||||
|
||||
// RateLimitedError represents the rate limit respond from slack
|
||||
// RateLimitedError represents the rate limit response from slack
|
||||
type RateLimitedError struct {
|
||||
RetryAfter time.Duration
|
||||
}
|
||||
|
||||
19
vendor/github.com/slack-go/slack/stars.go
generated
vendored
19
vendor/github.com/slack-go/slack/stars.go
generated
vendored
@@ -130,17 +130,18 @@ func (api *Client) ListStarsContext(ctx context.Context, params StarsParameters)
|
||||
// GetStarred returns a list of StarredItem items.
|
||||
//
|
||||
// The user then has to iterate over them and figure out what they should
|
||||
// be looking at according to what is in the Type.
|
||||
// for _, item := range items {
|
||||
// switch c.Type {
|
||||
// case "file_comment":
|
||||
// log.Println(c.Comment)
|
||||
// case "file":
|
||||
// ...
|
||||
// be looking at according to what is in the Type:
|
||||
//
|
||||
// for _, item := range items {
|
||||
// switch c.Type {
|
||||
// case "file_comment":
|
||||
// log.Println(c.Comment)
|
||||
// case "file":
|
||||
// ...
|
||||
// }
|
||||
//
|
||||
// }
|
||||
// This function still exists to maintain backwards compatibility.
|
||||
// I exposed it as returning []StarredItem, so it shall stay as StarredItem
|
||||
// I exposed it as returning []StarredItem, so it shall stay as StarredItem.
|
||||
func (api *Client) GetStarred(params StarsParameters) ([]StarredItem, *Paging, error) {
|
||||
return api.GetStarredContext(context.Background(), params)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user