Remove redundant error check

This commit is contained in:
Michael Hoffman 2025-01-29 11:12:28 -05:00
parent 9725a32f3e
commit e4d720ba22

View file

@ -38,19 +38,13 @@ func NewCmdView(f *cmdutil.Factory, runF func(*viewOptions) error) *cobra.Comman
Long: "View an autolink reference for a repository.",
Args: cobra.ExactArgs(1),
RunE: func(cmd *cobra.Command, args []string) error {
opts.BaseRepo = f.BaseRepo
httpClient, err := f.HttpClient()
if err != nil {
return err
}
opts.BaseRepo = f.BaseRepo
opts.ID = args[0]
if err != nil {
return err
}
opts.AutolinkClient = &AutolinkViewer{HTTPClient: httpClient}
if runF != nil {