From 81a25e4c3501b55ec3fb0cc7a114aa3721d63420 Mon Sep 17 00:00:00 2001 From: Micooz Date: Mon, 21 Aug 2017 22:15:02 +0800 Subject: [PATCH] core: fix presets in relay.js --- src/core/relay.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/relay.js b/src/core/relay.js index 0f1659a..07bfe3b 100644 --- a/src/core/relay.js +++ b/src/core/relay.js @@ -78,7 +78,7 @@ export class Relay extends EventEmitter { this._bsocket.setTimeout(__TIMEOUT__); let presets = __PRESETS__; // prepend "proxy" preset to the top of presets on client side - if (__IS_CLIENT__ && presets[0].name !== 'proxy') { + if (__IS_CLIENT__ && !['proxy', 'tunnel'].includes(presets[0].name)) { presets = [{name: 'proxy'}].concat(presets); } // add "tracker" preset to the preset list on both sides