Class: MapkitToken::MapkitTokenController
- Inherits:
-
ApplicationController
- Object
- ApplicationController
- MapkitToken::MapkitTokenController
- Defined in:
- app/controllers/mapkit_token/mapkit_token_controller.rb
Instance Method Summary collapse
- #apple_team_id ⇒ Object
- #auth_key ⇒ Object
- #auth_key_id ⇒ Object
- #base_url ⇒ Object
- #mapkit ⇒ Object
- #show ⇒ Object
Instance Method Details
#apple_team_id ⇒ Object
20 21 22 |
# File 'app/controllers/mapkit_token/mapkit_token_controller.rb', line 20 def apple_team_id mapkit[:apple_team_id] end |
#auth_key ⇒ Object
12 13 14 |
# File 'app/controllers/mapkit_token/mapkit_token_controller.rb', line 12 def auth_key File.read(mapkit[:auth_key_path]) end |
#auth_key_id ⇒ Object
16 17 18 |
# File 'app/controllers/mapkit_token/mapkit_token_controller.rb', line 16 def auth_key_id mapkit[:auth_key_id] end |
#base_url ⇒ Object
24 25 26 |
# File 'app/controllers/mapkit_token/mapkit_token_controller.rb', line 24 def base_url request.protocol + request.host end |
#mapkit ⇒ Object
4 5 6 7 8 9 10 |
# File 'app/controllers/mapkit_token/mapkit_token_controller.rb', line 4 def mapkit if Rails.application.respond_to?(:credentials) Rails.application.credentials.mapkit else Rails.application.secrets.mapkit.symbolize_keys end end |