Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我用devise_token_auth宝石。我想要覆盖resource_finder.rb对修改方法的关注provider。
devise_token_auth
resource_finder.rb
provider
我有一个类似的问题,我想在我的目录中覆盖一个方法,concerns/user.rb 我只是在我的文件中添加了一个同名的方法并且它有效user.rbmodels/model/user.rb
concerns/user.rb
user.rb
models/
model/user.rb
对您来说,您可以创建我们将resource_finder.rb在models/其下覆盖devise_token_auth concerns/resource_finder.rb
concerns/resource_finder.rb