1
NoMethodError: undefined method `[]' for #<ActiveRecord::Migration:0x00000001fe0fa0>
這個彈出每當我試圖運行耙:DB遷移無法遷移設計令牌驗證項目
I've been following this guide word for word
我有巨大的麻煩解釋堆棧跟蹤以及 Pastebin
NoMethodError: undefined method `[]' for #<ActiveRecord::Migration:0x00000001fe0fa0>
這個彈出每當我試圖運行耙:DB遷移無法遷移設計令牌驗證項目
I've been following this guide word for word
我有巨大的麻煩解釋堆棧跟蹤以及 Pastebin
這是令人難以置信的,但它是由發生器生成的遷移文件中的一個錯字(或類似的東西?)。
請參閱..._devise_token_auth_create_users.rb
文件db/migrate
目錄。你會看到在遷移文件的第一行有一個奇怪的[4.2]
字符串。
class DeviseTokenAuthCreateUsers < ActiveRecord::Migration[4.2]
只要從該行刪除那個奇怪的[4.2]
字符串和瞧。
但是,我必須承認,這個經歷讓我三次考慮在我的項目中使用這個寶石。