ruby on rails - Creating Devise user via JSON -
i'm able create new devise user via json. message saying saved user doesn't appear in database , can't login account.
def create respond_with actor.new(actor_params) end
i 201 when phone call suggesting works said isn't saving. what's issue?rails
you create new instance of model actor
, don't persist database.
def create @actor = actor.new(actor_params) if @actor.save respond_with @actor else # homecoming error end end
the illustration above, persist record, if there no validation or constraint error.
ruby-on-rails ruby devise
No comments:
Post a Comment