mirror of
https://github.com/turbot/steampipe.git
synced 2026-02-15 04:00:14 -05:00
12 lines
175 B
Go
12 lines
175 B
Go
package utils
|
|
|
|
import (
|
|
"context"
|
|
"errors"
|
|
)
|
|
|
|
func IsContextCancelled(ctx context.Context) bool {
|
|
err := ctx.Err()
|
|
return err != nil && errors.Is(err, context.Canceled)
|
|
}
|