From d495c11fea60e33bfd73e012557f0f101feb64f3 Mon Sep 17 00:00:00 2001 From: Ruben Daniels Date: Tue, 21 Apr 2015 02:01:11 +0000 Subject: [PATCH] Dont show start in debug mode when in debug mode --- plugins/c9.ide.plugins/debug.js | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/plugins/c9.ide.plugins/debug.js b/plugins/c9.ide.plugins/debug.js index 0b95e0b0..a97e00e2 100644 --- a/plugins/c9.ide.plugins/debug.js +++ b/plugins/c9.ide.plugins/debug.js @@ -55,14 +55,17 @@ define(function(require, exports, module) { menus.addItemByPath("Tools/~", new ui.divider(), 100000, plugin); menus.addItemByPath("Tools/Developer", null, 100100, plugin); - menus.addItemByPath("Tools/Developer/Start in Debug Mode", new ui.item({ - onclick: function(){ - var url = location.href + (location.href.indexOf("?") > -1 - ? "&debug=2" - : "?debug=2"); - window.open(url); - } - }), 900, plugin); + + if (!ENABLED) { + menus.addItemByPath("Tools/Developer/Start in Debug Mode", new ui.item({ + onclick: function(){ + var url = location.href + (location.href.indexOf("?") > -1 + ? "&debug=2" + : "?debug=2"); + window.open(url); + } + }), 900, plugin); + } if (!ENABLED) return;