Skip to content

Commit 2a9ac3f

Browse files
committed
HttpExtension: compatibility with nette/schema 2
1 parent c36d5c6 commit 2a9ac3f

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

composer.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@
2626
"phpstan/phpstan": "^0.12"
2727
},
2828
"conflict": {
29-
"nette/di": "<3.0.3"
29+
"nette/di": "<3.0.3",
30+
"nette/schema": "<1.1"
3031
},
3132
"suggest": {
3233
"ext-fileinfo": "to detect type of uploaded files",

src/Bridges/HttpDI/HttpExtension.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ public function getConfigSchema(): Nette\Schema\Schema
3535
'headers' => Expect::arrayOf('scalar|null')->default([
3636
'X-Powered-By' => 'Nette Framework 3',
3737
'Content-Type' => 'text/html; charset=utf-8',
38-
]),
38+
])->mergeDefaults(),
3939
'frames' => Expect::anyOf(Expect::string(), Expect::bool(), null)->default('SAMEORIGIN'), // X-Frame-Options
4040
'csp' => Expect::arrayOf('array|scalar|null'), // Content-Security-Policy
4141
'cspReportOnly' => Expect::arrayOf('array|scalar|null'), // Content-Security-Policy-Report-Only

0 commit comments

Comments
 (0)