def invalid_session?(json)
    return false unless json["name"]
    return false if @request.method == :logout
    raise SugarCRM::InvalidSession if json["name"] == "Invalid Session ID"
  end
def invalid_session?(json)
    return false unless json["name"]
    return false if @request.method == :logout
    raise SugarCRM::InvalidSession if json["name"] == "Invalid Session ID"
  end
Check if we got an invalid session error back
 something like:
 {"name"=>"Invalid Session ID",
  "number"=>11,
  "description"=>"The session ID is invalid"}