Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix detection of Rails::Engine for Rails 4 #45

Merged

Conversation

tjgrathwell
Copy link

We tried to upgrade to angularjs-rails 1.2.12, but now get this error:

couldn't find file 'angular'

when trying to load the application.

Assumedly the culprit is this commit: 137f7cf
We see that locally we get into the elsif defined? Sprockets condition, which is probably not what was intended for a Rails 4 project.

It works for us now if we use defined? ::Rails::Engine, but I'm not smart enough with engines to know exactly why or whether it will still work for Rails 3.

There was code saying if defined?(Rails::Engine), but that didn't work on our Rails 4 project.
It seems to work better as defined(::Rails::Engine).
hiravgandhi added a commit that referenced this pull request Feb 12, 2014
Fix detection of Rails::Engine for Rails 4
@hiravgandhi hiravgandhi merged commit 8bfe96b into hiravgandhi:master Feb 12, 2014
@Eric-Guo Eric-Guo mentioned this pull request Feb 12, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants