lib/ably/models/token.rb in ably-0.1.6 vs lib/ably/models/token.rb in ably-0.2.0

- old
+ new

@@ -2,11 +2,11 @@ # Authentication token issued by Ably in response to an token request class Token include Ably::Modules::ModelCommon DEFAULTS = { - capability: { "*" => ["*"] }, + capability: { '*' => ['*'] }, ttl: 60 * 60 # 1 hour } # Buffer in seconds given to the use of a token prior to it being considered unusable # For example, if buffer is 10s, the token can no longer be used for new requests 9s before it expires @@ -47,10 +47,10 @@ end # @!attribute [r] client_id # @return [String] Optional client ID assigned to this token def client_id - hash.fetch(:client_id) + hash[:client_id] end # @!attribute [r] nonce # @return [String] unique nonce used to generate Token and ensure token generation cannot be replayed def nonce