0

I'm in the process of updating rails from 4.1 to 5.2 I added the responders gem so respond_with is present. My ApplicationController now looks like this:

class ApplicationController < ActionController::API self.responder = ApplicationResponder respond_to :html

However, when I call respond_with I get this error:

 NoMethodError: undefined method `flash' for #<MyController>

I noticed in the responders README that there is a flash responder, however I do not want to use that.

1 Answers1

0

add the following line to "config/environments/production.rb"

config.middleware.use ActionDispatch::Flash