Method: SparkApi::Authentication::OAuth2Impl::GrantTypePassword#authenticate
- Defined in:
- lib/spark_api/authentication/oauth2_impl/grant_type_password.rb
#authenticate ⇒ Object
11 12 13 14 15 16 17 18 |
# File 'lib/spark_api/authentication/oauth2_impl/grant_type_password.rb', line 11 def authenticate new_session = nil if needs_refreshing? new_session = refresh end return new_session unless new_session.nil? create_session(token_params) end |