Skip to content

Commit

Permalink
Merge pull request #39 from joshbeard/spec-versions
Browse files Browse the repository at this point in the history
fix: request options and versions
  • Loading branch information
joshbeard authored Nov 8, 2023
2 parents d2d4c56 + 03fdd2d commit e6f8dbd
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions readme/readme.go
Original file line number Diff line number Diff line change
Expand Up @@ -321,7 +321,6 @@ func (c *Client) prepareRequest(request *APIRequest) (*http.Request, error) {
func (c *Client) paginatedRequest(apiRequest *APIRequest, page int) (*APIResponse, bool, error) {
// Set default values
perPage := 100
apiRequest.Version = ""

// Check for custom values in RequestOptions
if apiRequest.RequestOptions.PerPage != 0 {
Expand All @@ -330,9 +329,6 @@ func (c *Client) paginatedRequest(apiRequest *APIRequest, page int) (*APIRespons
if apiRequest.RequestOptions.Headers != nil {
apiRequest.Headers = apiRequest.RequestOptions.Headers
}
if apiRequest.RequestOptions.Version != "" {
apiRequest.Version = apiRequest.RequestOptions.Version
}

// Add pagination parameters to endpoint
baseEndpoint := apiRequest.Endpoint
Expand Down

0 comments on commit e6f8dbd

Please sign in to comment.