Skip to content

Commit

Permalink
Merge pull request #139 from taskrabbit/optional_assets
Browse files Browse the repository at this point in the history
check if using assets
  • Loading branch information
bleonard committed Mar 3, 2017
2 parents b3e7b7c + 1f13b1b commit 8a3e608
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/makara/middleware.rb
Expand Up @@ -37,7 +37,7 @@ def call(env)
# ignore asset paths
# consider allowing a filter proc to be provided in an initializer
def ignore_request?(env)
if defined?(Rails)
if defined?(Rails) && Rails.try(:application).try(:config).try(:assets).try(:prefix)
if env['PATH_INFO'].to_s =~ /^#{Rails.application.config.assets.prefix}/
return true
end
Expand Down

0 comments on commit 8a3e608

Please sign in to comment.