All the places where you are pulling out params and checking non nil, use a `paramify` block at the top of the handler, e.g.

    paramify :reset_password do
      attribute :code, type: String
      validates :code, presence: true
      attribute :password, type: String
      validates :password, presence: true
      attribute :password_confirmation, type: String
      validates :password_confirmation, presence: true
    end

This will give you verified parameters typecast into the appropriate type.  With the above, you can refer to `reset_password.code` and know that you are getting a non-nil String.  The `validates` stuff in `paramify` uses `ActiveModel` validations so you can do a lot of things.