method

has_key?

rails latest stable - Class: ActionDispatch::Request::Session
has_key?(key)
public

Returns true if the session has the given key or false.