Class: RestRails::Engine

Inherits:
Rails::Engine
  • Object
show all
Defined in:
lib/rest_rails/engine.rb

Class Method Summary collapse

Class Method Details

.mounted_pathObject



5
6
7
8
9
10
# File 'lib/rest_rails/engine.rb', line 5

def self.mounted_path
  route = Rails.application.routes.routes.detect do |route|
    self.in?([route.app, route.app.app])
  end
  route && (route.path.spec || route.path)
end