Skip to content

Commit

Permalink
pkg/op: Replace interface{} with any
Browse files Browse the repository at this point in the history
Signed-off-by: Thomas Hipp <[email protected]>
  • Loading branch information
monstermunchkin committed Sep 26, 2023
1 parent 177b970 commit a9db523
Show file tree
Hide file tree
Showing 14 changed files with 62 additions and 62 deletions.
16 changes: 8 additions & 8 deletions pkg/op/applicationtype_enumer.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pkg/op/auth_request.go
Original file line number Diff line number Diff line change
Expand Up @@ -501,7 +501,7 @@ func BuildAuthRequestCode(authReq AuthRequest, crypto Crypto) (string, error) {

// AuthResponseURL encodes the authorization response (successful and error) and sets it as query or fragment values
// depending on the response_mode and response_type
func AuthResponseURL(redirectURI string, responseType oidc.ResponseType, responseMode oidc.ResponseMode, response interface{}, encoder httphelper.Encoder) (string, error) {
func AuthResponseURL(redirectURI string, responseType oidc.ResponseType, responseMode oidc.ResponseMode, response any, encoder httphelper.Encoder) (string, error) {
uri, err := url.Parse(redirectURI)
if err != nil {
return "", oidc.ErrServerError().WithParent(err)
Expand Down
6 changes: 3 additions & 3 deletions pkg/op/auth_request_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -745,7 +745,7 @@ func TestAuthResponseURL(t *testing.T) {
redirectURI string
responseType oidc.ResponseType
responseMode oidc.ResponseMode
response interface{}
response any
encoder httphelper.Encoder
}
type res struct {
Expand All @@ -763,7 +763,7 @@ func TestAuthResponseURL(t *testing.T) {
"uri",
oidc.ResponseTypeCode,
"",
map[string]interface{}{"test": "test"},
map[string]any{"test": "test"},
&mockEncoder{
errors.New("error encoding"),
},
Expand Down Expand Up @@ -934,7 +934,7 @@ type mockEncoder struct {
err error
}

func (m *mockEncoder) Encode(src interface{}, dst map[string][]string) error {
func (m *mockEncoder) Encode(src any, dst map[string][]string) error {
if m.err != nil {
return m.err
}
Expand Down
2 changes: 1 addition & 1 deletion pkg/op/mock/authorizer.mock.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions pkg/op/mock/client.mock.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pkg/op/mock/configuration.mock.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pkg/op/mock/discovery.mock.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pkg/op/mock/key.mock.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions pkg/op/mock/signer.mock.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit a9db523

Please sign in to comment.