<commit_before>/*global Promise:true*/
'use strict';

var EventSource = global.EventSource || require('eventsource')
  , Promise = require('rsvp').Promise
  ;

var _source;

var Streamable = {
  listen: {
    value: function () {
      return new Promise(function (resolve, reject) {
        var source
          , url = this.url;

        if (this.token) {
          url = url + '?x-auth-token=' + this.token.token;
        }

        try {<commit_msg>Fix stream sending undefined as an x-auth-token<commit_after>/*global Promise:true*/
'use strict';

var EventSource = global.EventSource || require('eventsource')
  , Promise = require('rsvp').Promise
  ;

var _source;

var Streamable = {
  listen: {
    value: function () {
      return new Promise(function (resolve, reject) {
        var source
          , url = this.url;

        if (this.token && this.token.token) {
          url = url + '?x-auth-token=' + this.token.token;
        }

        try {
{'fraction_non_alphanumeric': 0.1375, 'fraction_numerical': 0.0, 'mean_word_length': 2.419928825622776, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5290906', 'n_tokens_mistral': 295, 'n_tokens_neox': 290, 'n_words': 73}