Commit c1e8c63515f207be1fbcdec27b94a75c1660dc7b
1 parent
ae7db5ab17
Exists in
master
Only load control panel if it is defined on config
Showing 1 changed file with 5 additions and 1 deletions Side-by-side Diff
gateway/pull.js
... | ... | @@ -3,7 +3,11 @@ const request = require('request'); |
3 | 3 | const config = require('../config'); |
4 | 4 | const logger = require('../logger'); |
5 | 5 | const matrix = require('../matrix'); |
6 | -require('../control-panel'); | |
6 | + | |
7 | +if (config.control_panel && (config.control_panel.listen_port || config.control_panel.port)) { | |
8 | + require('../control-panel'); | |
9 | +} | |
10 | + | |
7 | 11 | const heartbeat = require('../heartbeat'); |
8 | 12 | const core_url = require('../core-url'); |
9 | 13 |