<commit_before>// Room model
// TODO Needs tests
Room = {
  createRoom: function(socket, data){

    //TODO sanity check
  	// subscribe the client to the room
    // Manager level
  	socket.join(data.room);
  },

  joinRoom: function(socket, data){

    //TODO sanity check
    // joins a room if it doesn't exist
    //Manager Level
    socket.join(data.room);
  }
};

exports.Room = Room;<commit_msg>Beggining work on the rooms module<commit_after>// Room model
// TODO Needs tests


function Rooms() {
  this.chatrepos = {}  // Hash containing chat repositories
}


Rooms.prototype.
Room = {
  createRoom: function(socket, data){

    //TODO sanity check
  	// subscribe the client to the room
    // Manager level
  	socket.join(data.room);
  },

  joinRoom: function(socket, data){

    //TODO sanity check
    // joins a room if it doesn't exist
    //Manager Level
    socket.join(data.room);
  }
};

/**
 * Simple boolean returns true if room is in chat
 */
ChatRepo.prototype.hasRoom = function (room_id) {
  return (room_id in this.questionLog);
}

/**
 * Deletes a chat log
 */
ChatRepo.prototype.purgeRoom = function(room_id) {
    delete this.questionLog[room_id];
}

exports.Room = Room;
{'fraction_non_alphanumeric': 0.12146422628951747, 'fraction_numerical': 0.0, 'mean_word_length': 2.8434504792332267, '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': '3658842', 'n_tokens_mistral': 401, 'n_tokens_neox': 379, 'n_words': 116}