Skip to content

Commit 73e179e

Browse files
committed
disable debugger if you are in testbox mode
1 parent 4676ef5 commit 73e179e

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

ModuleConfig.cfc

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -166,8 +166,13 @@ component {
166166
// Configure the debugging mode from the loaded app settings
167167
wirebox.getInstance( "debuggerService@cbDebugger" ).setDebugMode( variables.settings.debugMode );
168168

169-
// Only activate interceptions and collectors if master switch is on
170-
if ( variables.settings.enabled ) {
169+
// Only activate interceptions and collectors if master switch is on or in test mode disable it
170+
if (
171+
variables.settings.enabled && !findNoCase(
172+
"MockController",
173+
getMetadata( controller ).name
174+
)
175+
) {
171176
/******************** REQUEST COLLECTOR ************************************/
172177

173178
controller

0 commit comments

Comments
 (0)