Skip to content

Commit

Permalink
Remove the --user-agent flag from the watch activity command
Browse files Browse the repository at this point in the history
  • Loading branch information
jgustie committed Dec 12, 2022
1 parent feff161 commit f520059
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions pkg/command/activity.go
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,6 @@ func NewWatchActivityCommand(cfg Config) *cobra.Command {

feedTemplateText string
itemTemplateText string
userAgent string
)

cmd := &cobra.Command{
Expand All @@ -109,7 +108,6 @@ func NewWatchActivityCommand(cfg Config) *cobra.Command {
cmd.Flags().BoolVar(&deleteItems, "delete", false, "delete new items")
cmd.Flags().StringVar(&feedTemplateText, "feed-template", `{{ template "ActivityFeed" . }}`, "the feed `template` used to render the activity feed")
cmd.Flags().StringVar(&itemTemplateText, "item-template", `{{ template "ActivityItem" . }}`, "the item `template` used to render the items")
cmd.Flags().StringVar(&userAgent, "user-agent", "", "override the User-Agent `header` used when making requests")
cmd.Flag("feed-template").Hidden = true
cmd.Flag("item-template").Hidden = true
cmd.Flag("user-agent").Hidden = true
Expand Down Expand Up @@ -146,11 +144,6 @@ func NewWatchActivityCommand(cfg Config) *cobra.Command {
return err
}

// Override the user agent for debugging
if userAgent != "" {
ctx = context.WithValue(ctx, "User-Agent", userAgent)
}

s := &applications.PollingSubscriber{
API: applications.NewAPI(client),
PollInterval: pollInterval,
Expand Down

0 comments on commit f520059

Please sign in to comment.