Skip to content

Commit bed40d1

Browse files
authored
Remove unnecessary use of fmt.Sprintf (#2819)
1 parent 1e7c685 commit bed40d1

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

github/admin_stats.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ package github
77

88
import (
99
"context"
10-
"fmt"
1110
)
1211

1312
// AdminStats represents a variety of stats of a GitHub Enterprise
@@ -155,7 +154,7 @@ func (s RepoStats) String() string {
155154
//
156155
// GitHub API docs: https://docs.github.com/en/rest/enterprise-admin/admin_stats/
157156
func (s *AdminService) GetAdminStats(ctx context.Context) (*AdminStats, *Response, error) {
158-
u := fmt.Sprintf("enterprise/stats/all")
157+
u := "enterprise/stats/all"
159158
req, err := s.client.NewRequest("GET", u, nil)
160159
if err != nil {
161160
return nil, nil, err

github/codespaces.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ type ListCodespacesOptions struct {
126126
//
127127
// GitHub API docs: https://docs.github.com/en/rest/codespaces/codespaces?apiVersion=2022-11-28#list-codespaces-for-the-authenticated-user
128128
func (s *CodespacesService) List(ctx context.Context, opts *ListCodespacesOptions) (*ListCodespaces, *Response, error) {
129-
u := fmt.Sprint("user/codespaces")
129+
u := "user/codespaces"
130130
u, err := addOptions(u, opts)
131131
if err != nil {
132132
return nil, nil, err

0 commit comments

Comments
 (0)