mirror of
https://github.com/nov/fb_graph2
synced 2023-03-27 23:22:15 -04:00
use Graph API v2.11
This commit is contained in:
parent
9fde775e8a
commit
7611b69e5f
3 changed files with 3 additions and 4 deletions
|
@ -8,7 +8,7 @@ module FbGraph2
|
||||||
mattr_accessor :root_url, :api_version, :gem_version, :logger, :debugging, :_http_config_, :object_classes
|
mattr_accessor :root_url, :api_version, :gem_version, :logger, :debugging, :_http_config_, :object_classes
|
||||||
|
|
||||||
self.root_url = 'https://graph.facebook.com'
|
self.root_url = 'https://graph.facebook.com'
|
||||||
self.api_version = 'v2.10'
|
self.api_version = 'v2.11'
|
||||||
self.gem_version = File.read(File.join(__dir__, '../VERSION')).strip
|
self.gem_version = File.read(File.join(__dir__, '../VERSION')).strip
|
||||||
self.logger = Logger.new(STDOUT)
|
self.logger = Logger.new(STDOUT)
|
||||||
self.logger.progname = 'FbGraph2'
|
self.logger.progname = 'FbGraph2'
|
||||||
|
|
|
@ -17,7 +17,6 @@ module FbGraph2
|
||||||
end
|
end
|
||||||
|
|
||||||
def verify!(client)
|
def verify!(client)
|
||||||
digest = OpenSSL::Digest::SHA256.new
|
|
||||||
signature = OpenSSL::HMAC.digest OpenSSL::Digest::SHA256.new, client.secret, @payload_str
|
signature = OpenSSL::HMAC.digest OpenSSL::Digest::SHA256.new, client.secret, @payload_str
|
||||||
raise VerificationFailed.new('Verification failed') unless @signature == signature
|
raise VerificationFailed.new('Verification failed') unless @signature == signature
|
||||||
instantiate client
|
instantiate client
|
||||||
|
|
|
@ -6,7 +6,7 @@ describe FbGraph2 do
|
||||||
|
|
||||||
context 'as default' do
|
context 'as default' do
|
||||||
its(:logger) { should be_a Logger }
|
its(:logger) { should be_a Logger }
|
||||||
its(:api_version) { should == 'v2.10' }
|
its(:api_version) { should == 'v2.11' }
|
||||||
its(:root_url) { should == 'https://graph.facebook.com' }
|
its(:root_url) { should == 'https://graph.facebook.com' }
|
||||||
it { should_not be_debugging }
|
it { should_not be_debugging }
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue