You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
isAjax in oauthproxy.go should be iterating through different mime types for the Accept: field and return true if application/json is found.
Current Behavior
isAjax iterates over a single string. If this string matches application/json exactly, isAjax works as intended. With multiple mime types, as allowed by standards and default for Axios, isAjax fails to find the correct mime type. The following test fails, proving the point.
Expected Behavior
isAjax
inoauthproxy.go
should be iterating through different mime types for theAccept:
field and returntrue
ifapplication/json
is found.Current Behavior
isAjax
iterates over a single string. If this string matchesapplication/json
exactly,isAjax
works as intended. With multiple mime types, as allowed by standards and default for Axios,isAjax
fails to find the correct mime type. The following test fails, proving the point.Possible Solution
Fix the loop to actually iterate over multiple mime types.
The text was updated successfully, but these errors were encountered: