Skip to content

Commit 39affa8

Browse files
authored
Added the info that the forceEnable config value accepts a callable
1 parent 663491e commit 39affa8

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

docs/en/index.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,12 @@ Configuration
5050
// Before loading DebugKit
5151
Configure::write('DebugKit.forceEnable', true);
5252

53+
You can also provide a callable::
54+
55+
Configure::write('DebugKit.forceEnable', function() {
56+
return $_SERVER['REMOTE_ADDR'] === '192.168.2.182';
57+
});
58+
5359
* ``DebugKit.ignorePathsPattern`` - Regex pattern (including delimiter) to ignore paths.
5460
DebugKit won't save data for request URLs that match this regex. Defaults to ``null``::
5561

0 commit comments

Comments
 (0)