NoMethodError:推送到Heroku时,nil:NilClass的未定义方法`[]' [英] NoMethodError: undefined method `[]' for nil:NilClass when pushing to Heroku
本文介绍了NoMethodError:推送到Heroku时,nil:NilClass的未定义方法`[]'的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
在这里拉动菜鸟.
推送到Heroku时遇到问题(NoMethodError:nil:NilClass的未定义方法"[]").我什至不知道应该从哪里着手解决这个问题.
I ran into a problem when pushing to Heroku (NoMethodError: undefined method `[]' for nil:NilClass). I'm not even sure where I should start looking to correct this problem.
remote: -----> Preparing app for Rails asset pipeline
remote: Running: rake assets:precompile
remote: I, [2015-10-04T23:27:47.570225 #397] INFO -- : Writing /tmp/build_1a2df3ea1a8121d7fba6ab542c59ba85/public/assets/application-7fbbda11565ec9a0d53aaeb338357988655d4d81476f99312f8a66772c63bea9.js
remote: rake aborted!
remote: NoMethodError: undefined method `[]' for nil:NilClass
remote: /tmp/build_1a2df3ea1a8121d7fba6ab542c59ba85/vendor/bundle/ruby/2.2.0/gems/sprockets-3.3.5/lib/sprockets/sass_processor.rb:266:in `sprockets_context'
remote:
推荐答案
我能够通过将我的application.css文件重命名为application.css.scss来解决此问题.
I was able to resolve this problem by renaming my application.css file to application.css.scss.
这篇关于NoMethodError:推送到Heroku时,nil:NilClass的未定义方法`[]'的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文