Skip to content

Commit

Permalink
Rename misspelled field (radius-project#7692)
Browse files Browse the repository at this point in the history
# Description

Rename misspelled field

Found this making another change, and it made sense to split off. 

## Type of change

- This pull request is a minor refactor, code cleanup, test improvement,
or other maintenance task and doesn't change the functionality of Radius
(issue link optional).

Signed-off-by: Ryan Nowak <nowakra@gmail.com>
  • Loading branch information
rynowak authored Jun 17, 2024
1 parent d26a411 commit 86b4397
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions pkg/armrpc/api/v1/armrequestcontext.go
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ type ARMRequestContext struct {
// HTTPMethod represents the original method.
HTTPMethod string
// OriginalURL represents the original URL of the request.
OrignalURL url.URL
OriginalURL url.URL
}

// FromARMRequest extracts proxy request headers from http.Request.
Expand Down Expand Up @@ -229,8 +229,8 @@ func FromARMRequest(r *http.Request, pathBase, location string) (*ARMRequestCont
SkipToken: r.URL.Query().Get(SkipTokenParameterName),
Top: queryItemCount,

HTTPMethod: r.Method,
OrignalURL: *r.URL,
HTTPMethod: r.Method,
OriginalURL: *r.URL,
}

return rpcCtx, nil
Expand Down
2 changes: 1 addition & 1 deletion pkg/ucp/frontend/controller/radius/proxy.go
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ func (p *ProxyController) Run(ctx context.Context, w http.ResponseWriter, req *h
// use the original URL instead.
requestCtx := v1.ARMRequestContextFromContext(ctx)
id := requestCtx.ResourceID
relativePath := middleware.GetRelativePath(p.Options().PathBase, requestCtx.OrignalURL.Path)
relativePath := middleware.GetRelativePath(p.Options().PathBase, requestCtx.OriginalURL.Path)

downstreamURL, err := resourcegroups.ValidateDownstream(ctx, p.StorageClient(), id)
if errors.Is(err, &resourcegroups.NotFoundError{}) {
Expand Down

0 comments on commit 86b4397

Please sign in to comment.