return false if authorized?
self.user = user
self.authorized_at = Time.now
- self.verifier = OAuth::Helper.generate_key(16)[0,20] unless oauth10?
+ self.verifier = OAuth::Helper.generate_key(20)[0,20] unless oauth10?
self.save
end
params[p] = read_attribute(p)
}
- access_token = AccessToken.create(params)
+ access_token = AccessToken.create(params, :without_protection => true)
invalidate!
access_token
end
end
def oob?
- self.callback_url=='oob'
+ callback_url.nil? || callback_url.downcase == 'oob'
end
def oauth10?