mirror of
https://github.com/discourse/discourse.git
synced 2025-05-21 18:12:32 +08:00
FEATURE: Nokogumbo (#9577)
* FEATURE: Nokogumbo Use Nokogumbo HTML parser.
This commit is contained in:

committed by
GitHub

parent
b8b1cbbfb9
commit
9bff0882c3
@ -238,7 +238,7 @@ describe UserApiKeysController do
|
||||
SiteSetting.min_trust_level_for_user_api_key = 0
|
||||
post "/user-api-key", params: args
|
||||
expect(response.status).not_to eq(302)
|
||||
payload = Nokogiri::HTML(response.body).at('code').content
|
||||
payload = Nokogiri::HTML5(response.body).at('code').content
|
||||
encrypted = Base64.decode64(payload)
|
||||
key = OpenSSL::PKey::RSA.new(private_key)
|
||||
parsed = JSON.parse(key.private_decrypt(encrypted))
|
||||
|
Reference in New Issue
Block a user