Skip to content

Commit ec094ce

Browse files
authored
Merge pull request #63 from zlodes/dev-treshold-dotenv
Ability to change queries treshold via .env
2 parents 3f68947 + 548cc1d commit ec094ce

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ return [
5252
* Threshold level for the N+1 query detection. If a relation query will be
5353
* executed more then this amount, the detector will notify you about it.
5454
*/
55-
'threshold' => 1,
55+
'threshold' => (int) env('QUERY_DETECTOR_TRESHOLD', 1),
5656

5757
/*
5858
* Here you can whitelist model relations.

config/config.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
* Threshold level for the N+1 query detection. If a relation query will be
1212
* executed more then this amount, the detector will notify you about it.
1313
*/
14-
'threshold' => 1,
14+
'threshold' => (int) env('QUERY_DETECTOR_TRESHOLD', 1),
1515

1616
/*
1717
* Here you can whitelist model relations.

0 commit comments

Comments
 (0)