|
8071 | 8071 |
|
8072 | 8072 |
|
8073 | 8073 | // Initialise the Websocket connection |
8074 | | - websocket = (0, _websocket.initialise)(("http://35.162.145.41:8000")); |
| 8074 | + websocket = (0, _websocket.initialise)(("http://35.167.249.144:8000")); |
8075 | 8075 |
|
8076 | 8076 | websocket.on('data', function (action) { |
8077 | 8077 | var reduxAction = (0, _mapWebsocketToRedux2.default)(store, action); |
|
8276 | 8276 | // Assign the global_env to process.env |
8277 | 8277 | // GLOBAL_ENV is set in webpack using the definePlugin |
8278 | 8278 | if (true) { |
8279 | | - Object.assign(process.env, ({"APP_TYPE":"desktop","NODE_ENV":"production","WEBSITE_URL":"http://localhost:3333","API_SERVER":"http://35.162.145.41","WEBSOCKET_SERVER":"http://35.162.145.41:8000","ELECTRON_CRASH_REPORT_SERVER":"http://35.162.145.41:2096"})); |
| 8279 | + Object.assign(process.env, ({"APP_TYPE":"desktop","NODE_ENV":"production","WEBSITE_URL":"http://localhost:3333","API_SERVER":"http://35.167.249.144","WEBSOCKET_SERVER":"http://35.167.249.144:8000","ELECTRON_CRASH_REPORT_SERVER":"http://35.167.249.144:2096"})); |
8280 | 8280 | } |
8281 | 8281 |
|
8282 | 8282 | // Initialise Reporting |
8283 | 8283 | (0, _electronCrash2.default)(); |
8284 | 8284 | (0, _ravenMain2.default)(); |
8285 | 8285 |
|
8286 | | - _axios2.default.defaults.baseURL = ("http://35.162.145.41") + '/'; |
| 8286 | + _axios2.default.defaults.baseURL = ("http://35.167.249.144") + '/'; |
8287 | 8287 |
|
8288 | 8288 | /***/ }, |
8289 | 8289 | /* 299 */ |
|
10914 | 10914 | _electron.crashReporter.start({ |
10915 | 10915 | companyName: 'Stemn', |
10916 | 10916 | productName: 'Stemn Desktop', |
10917 | | - submitURL: ("http://35.162.145.41:2096"), |
| 10917 | + submitURL: ("http://35.167.249.144:2096"), |
10918 | 10918 | autoSubmit: true, |
10919 | 10919 | extra: { |
10920 | 10920 | app_version: _package.version, |
@@ -12644,10 +12644,10 @@ |
12644 | 12644 | value: true |
12645 | 12645 | }); |
12646 | 12646 | // Sentry DSN for the Electron Main project |
12647 | | - var sentryPrivate = exports.sentryPrivate = 'http://b882145da3624d20a8b388b1f499f1d7:70c3c691cdbc48529ace050e45b016f6@35.162.145.41:9000/4'; |
| 12647 | + var sentryPrivate = exports.sentryPrivate = 'http://b882145da3624d20a8b388b1f499f1d7:70c3c691cdbc48529ace050e45b016f6@35.167.249.144:9000/4'; |
12648 | 12648 |
|
12649 | 12649 | // Sentry DSN for the Electron Renderer project |
12650 | | - var sentryPublic = exports.sentryPublic = 'http://fae90f76026746ecbb42464ba51ec2ec@35.162.145.41:9000/2'; |
| 12650 | + var sentryPublic = exports.sentryPublic = 'http://fae90f76026746ecbb42464ba51ec2ec@35.167.249.144:9000/2'; |
12651 | 12651 |
|
12652 | 12652 | /***/ }, |
12653 | 12653 | /* 362 */ |
|
13431 | 13431 | appIcon = new _electron.Tray(trayIcon); |
13432 | 13432 | appIcon.setToolTip('Stemn Desktop'); |
13433 | 13433 |
|
13434 | | - if (_process2.default.platform == 'win32') { |
13435 | | - |
13436 | | - // appIcon.setContextMenu(contextMenu); |
13437 | | - } |
13438 | | - |
13439 | 13434 | var lastClickTime = Date.now(); |
13440 | 13435 |
|
13441 | 13436 | appIcon.on('right-click', function (event, trayBounds) { |
|
13471 | 13466 | } |
13472 | 13467 | }, { |
13473 | 13468 | label: 'Account Settings', |
13474 | | - enabled: (auth.authToken && auth.user._id) === true, |
13475 | | - onClick: function onClick() { |
| 13469 | + enabled: auth.authToken && auth.user._id ? true : false, |
| 13470 | + click: function click() { |
13476 | 13471 | windows.main.show(); |
13477 | 13472 | dispatch((0, _reactRouterRedux.push)({ |
13478 | 13473 | pathname: '/settings/account', |
|
21384 | 21379 | description: description |
21385 | 21380 | } |
21386 | 21381 | }).then(function (response) { |
21387 | | - console.log(); |
21388 | 21382 | dispatch((0, _ToastsActions.show)({ |
21389 | 21383 | title: response.data.files.length + ' files commited', |
21390 | 21384 | actions: [{ |
|
72983 | 72977 | }); |
72984 | 72978 |
|
72985 | 72979 | exports.default = function (fileMeta) { |
72986 | | - return fileMeta.project && fileMeta.project._id ? ("http://35.162.145.41") + '/api/v1/sync/download/' + fileMeta.project._id + '/' + fileMeta.fileId + (fileMeta.revisionId ? '?revisionId=' + fileMeta.revisionId : '') : ("http://35.162.145.41") + '/api/v1/remote/download/' + fileMeta.provider + '/' + fileMeta.fileId + (fileMeta.revisionId ? '?revisionId=' + fileMeta.revisionId : ''); |
| 72980 | + return fileMeta.project && fileMeta.project._id ? ("http://35.167.249.144") + '/api/v1/sync/download/' + fileMeta.project._id + '/' + fileMeta.fileId + (fileMeta.revisionId ? '?revisionId=' + fileMeta.revisionId : '') : ("http://35.167.249.144") + '/api/v1/remote/download/' + fileMeta.provider + '/' + fileMeta.fileId + (fileMeta.revisionId ? '?revisionId=' + fileMeta.revisionId : ''); |
72987 | 72981 | }; |
72988 | 72982 |
|
72989 | 72983 | module.exports = exports['default']; |
|
73281 | 73275 |
|
73282 | 73276 | var dest = _path2.default.join(folderPath, name); |
73283 | 73277 | var onProgress = function onProgress(progressPerc) { |
73284 | | - console.log(onProgressAction, progressPerc); |
| 73278 | + // console.log(onProgressAction, progressPerc); |
73285 | 73279 | }; |
73286 | 73280 | return (0, _downloadToDisk2.default)({ url: url, params: params, dest: dest, extract: extract, onProgress: onProgress }).then(function (response1) { |
73287 | 73281 | // If extract is true, we rename the files, then save them to the store |
|
73341 | 73335 | var getFile = function getFile() { |
73342 | 73336 | // If there is a render url, we check the render.status, otherwise we just download directly |
73343 | 73337 | if (!renderUrl) { |
| 73338 | + console.log(url); |
73344 | 73339 | return downloadToDiskAndSave({ key: key, url: url, params: params, name: name, extract: extract, onProgressAction: onProgressAction }).then(processResult); |
73345 | 73340 | } else { |
73346 | 73341 | return (0, _axios2.default)({ url: renderUrl, params: params }).then(function (response) { |
|
73352 | 73347 | }; |
73353 | 73348 |
|
73354 | 73349 | // If we have a cache entry, get the file |
73355 | | - return fileCache[key] ? fsPromise.stat(_path2.default.join(folderPath, fileCache[key].name)).then(processResult).catch(getFile) : getFile(); |
| 73350 | + return fileCache[key] ? fsPromise.stat(_path2.default.join(folderPath, fileCache[key].name)).then(processResult).catch(getFile) |
| 73351 | + // Else, we download the file. |
| 73352 | + : getFile(); |
73356 | 73353 | }; |
73357 | 73354 |
|
73358 | 73355 | /******************************************************* |
|
95279 | 95276 |
|
95280 | 95277 | // unzip event uses close, but all others use end |
95281 | 95278 | if (extract) { |
95282 | | - // console.log('Download to Disk Complete', {url, params, dest, onProgress, extract}); |
95283 | 95279 | file.on('close', function (response) { |
95284 | 95280 | resolve({ |
95285 | 95281 | size: total, |
|
95295 | 95291 | }); |
95296 | 95292 | } |
95297 | 95293 | stream.pipe(file); |
| 95294 | + }).catch(function (error) { |
| 95295 | + reject(error.response); |
95298 | 95296 | }); |
95299 | 95297 | }); |
95300 | 95298 | }; |
@@ -113258,6 +113256,7 @@ |
113258 | 113256 | case 'FILES/GET_FILE_PENDING': |
113259 | 113257 | return _icepick2.default.assocIn(state, ['fileData', action.meta.cacheKey, 'loading'], true); |
113260 | 113258 | case 'FILES/GET_FILE_REJECTED': |
| 113259 | + console.log(action.payload); |
113261 | 113260 | return _icepick2.default.assocIn(state, ['fileData', action.meta.cacheKey], { |
113262 | 113261 | error: action.payload.data, |
113263 | 113262 | loading: false |
@@ -150547,7 +150546,7 @@ |
150547 | 150546 | port: 49554 |
150548 | 150547 | }, |
150549 | 150548 | websocket: { |
150550 | | - host: ("http://35.162.145.41:8000") || 'localhost', |
| 150549 | + host: ("http://35.167.249.144:8000") || 'localhost', |
150551 | 150550 | port: 8000 |
150552 | 150551 | } |
150553 | 150552 | }; |
|
0 commit comments