Add chat

This commit is contained in:
brunosimon
2017-07-30 22:49:08 +02:00
parent f8246fd60f
commit 910a63234d
5 changed files with 927 additions and 2 deletions
+3 -1
View File
@@ -3,6 +3,7 @@
// Dependencies
const slug = require('slug')
const Files = require('./files.js')
const Chat = require('./chat.js')
const AdmZip = require('adm-zip')
const glob = require('glob')
const fs = require('fs')
@@ -21,6 +22,7 @@ class Project
this.excludeRegex = new RegExp(_options.excludeRegex)
this.zipNeedsUpdate = true
this.files = new Files(this.config, { projectSocket: this.projectSocket })
this.chat = new Chat(this.config, { slug: this.slug })
this.date = new Date()
// Add test contents
@@ -38,7 +40,7 @@ class Project
setSocket()
{
// Save original socket and create a channel for this specific project
// Create a channel for this specific project
this.projectSocket = this.config.socket.of('/project/' + this.slug)
// Connection event