lib/rest-firebase.rb in rest-firebase-0.9.3 vs lib/rest-firebase.rb in rest-firebase-0.9.4

- old
+ new

@@ -97,13 +97,16 @@ input = [header, claims].map{ |d| base64url(Json.encode(d)) }.join('.') # http://tools.ietf.org/html/draft-ietf-oauth-json-web-token-20 "#{input}.#{base64url(Hmac.sha256(secret, input))}" end + def query + {:auth => auth} + end + private def base64url str; [str].pack('m').tr('+/', '-_'); end - def default_query ; {:auth => auth}; end def default_auth ; generate_auth ; end def default_auth_ttl; 82800 ; end def default_iat ; Time.now.to_i ; end def check_auth @@ -112,6 +115,7 @@ end class RestFirebase include RestFirebase::Client self.event_source_class = EventSource + const_get(:Struct).send(:remove_method, :query=) end