         @sock.on 'error', (error) =>
           @emit 'error', error
 
-          console.error "WebSocket error for namespace '#{@namespace}' topic [#{jsonify(@attributes)}] : #{error}\n#{error.stack}"
+          console.error "WebSocket error for namespace '#{@namespace}' topic #{jsonify(@attributes)} : #{error}\n#{error.stack}"
 
         # Received a message
         @sock.on 'message', (msg) =>


          else
            @emit 'close'
            console.log "Push WebSocket closed for namespace '#{@namespace}' topic [#{jsonify(@attributes)}]"

        # The WebSocket connection has been established
        @sock.on 'open', =>
          console.log "Push WebSocket opened for namespace '#{@namespace}' topic [#{jsonify(@attributes)}]"

          @emit 'open'



            reconnect = =>
              @connect().then =>
                console.log "Push WebSocket replaced for namespace '#{@namespace}' topic #{jsonify(@attributes)}"
                @emit 'reconnect'
              .catch (error) =>
                console.error "Error replacing push WebSocket for namespace '#{@namespace}' topic #{jsonify(@attributes)} : ${error}\n${error.stack}"
                @emit 'error', error
            
            console.log "Connection closed. Reconnecting in 5 seconds."
