Browse Source

fixed 头歌接口增加安全参数

pull/346/head
xxq250 1 year ago
parent
commit
6ba0374119
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      app/libs/educoder_oauth/service.rb

+ 1
- 1
app/libs/educoder_oauth/service.rb View File

@@ -7,7 +7,7 @@ module EducoderOauth::Service
begin
Rails.logger.info("[EducoderOauth] [#{method.to_s.upcase}] #{url} || #{params}")

client = Faraday.new(url: EducoderOauth.base_url, headers: {'X-EDU-Timestamp' => Time.now.to_i})
client = Faraday.new(url: EducoderOauth.base_url, headers: {'X-EDU-Timestamp' => "#{Time.now.to_i}"})
response = client.public_send(method, url, params)
result = JSON.parse(response.body)



Loading…
Cancel
Save