diff --git a/.env.staging b/.env.staging index e091a3230..74355abe2 100644 --- a/.env.staging +++ b/.env.staging @@ -1,5 +1,5 @@ # just a flag -NODE_ENV = 'production' +NODE_ENV = 'test' # base api VUE_APP_BASE_API = 'https://test.joylink.club/jlcloud' diff --git a/src/utils/sock.js b/src/utils/sock.js index ffdba8c13..371093ca9 100644 --- a/src/utils/sock.js +++ b/src/utils/sock.js @@ -10,6 +10,7 @@ import Stomp from 'stompjs'; // var Stomp = require('stompjs'); const isDev = process.env.NODE_ENV === 'development'; +const isTest = process.env.NODE_ENV === 'test'; const websocketUrl = `${getBaseUrl()}/joylink-websocket?token=`; // const websocketUrl = `http://192.168.3.6:9000/joylink-websocket?token=`; @@ -164,7 +165,7 @@ StompClient.prototype = { closeStompDebug() { if (this.clientIns) { this.clientIns.debug = undefined; - if (isDev) { + if (isDev || isTest) { this.clientIns.debug = function (message) { console.debug(message); };