[英]Rails pathname missing in environment.rb
當我嘗試安裝Diaspora *並在我的rake db:setup之后,嘗試從瀏覽器中打開它時出現以下錯誤:
NameError: uninitialized constant Pathname
/Users/myself/diaspora/config/environment.rb:15:in `<top (required)>'
第15行是評論后的第一行:
# Load the rails application
require Pathname.new(__FILE__).dirname.expand_path.join('application')
require Rails.root.join("lib", "exceptions")
我也在用Pow。
在environment.rb
的頂部添加require 'pathname'
,以使該核心Ruby庫可用。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.