From 846c5ceae5a2a71447b8b311cdabd63c4f85f87e Mon Sep 17 00:00:00 2001 From: guoguangwu Date: Mon, 26 Jun 2023 15:29:21 +0800 Subject: [PATCH] chore: unnecessary use of fmt.Sprint --- github/admin_stats.go | 3 +-- github/codespaces.go | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/github/admin_stats.go b/github/admin_stats.go index ef294f44791..17e568f62b2 100644 --- a/github/admin_stats.go +++ b/github/admin_stats.go @@ -7,7 +7,6 @@ package github import ( "context" - "fmt" ) // AdminStats represents a variety of stats of a GitHub Enterprise @@ -155,7 +154,7 @@ func (s RepoStats) String() string { // // GitHub API docs: https://docs.github.com/en/rest/enterprise-admin/admin_stats/ func (s *AdminService) GetAdminStats(ctx context.Context) (*AdminStats, *Response, error) { - u := fmt.Sprintf("enterprise/stats/all") + u := "enterprise/stats/all" req, err := s.client.NewRequest("GET", u, nil) if err != nil { return nil, nil, err diff --git a/github/codespaces.go b/github/codespaces.go index a260c227de7..cd8b0e5bee5 100644 --- a/github/codespaces.go +++ b/github/codespaces.go @@ -126,7 +126,7 @@ type ListCodespacesOptions struct { // // GitHub API docs: https://docs.github.com/en/rest/codespaces/codespaces?apiVersion=2022-11-28#list-codespaces-for-the-authenticated-user func (s *CodespacesService) List(ctx context.Context, opts *ListCodespacesOptions) (*ListCodespaces, *Response, error) { - u := fmt.Sprint("user/codespaces") + u := "user/codespaces" u, err := addOptions(u, opts) if err != nil { return nil, nil, err