Skip to content

Commit e688b3b

Browse files
committed
Fix System Configuration Path References
- Fix default system config value paths in config.xml - Fix system config path references in cors headers plugin
1 parent 71ff3ed commit e688b3b

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

Plugin/CorsHeadersPlugin.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ public function __construct(
4747
*/
4848
protected function getOriginUrl()
4949
{
50-
return $this->scopeConfig->getValue('corsRequests/general/origin_url',
50+
return $this->scopeConfig->getValue('web/corsRequests/origin_url',
5151
\Magento\Store\Model\ScopeInterface::SCOPE_STORE);
5252
}
5353

@@ -57,7 +57,7 @@ protected function getOriginUrl()
5757
*/
5858
protected function getAllowCredentials()
5959
{
60-
return (bool) $this->scopeConfig->getValue('corsRequests/general/allow_credentials',
60+
return (bool) $this->scopeConfig->getValue('web/corsRequests/allow_credentials',
6161
\Magento\Store\Model\ScopeInterface::SCOPE_STORE);
6262
}
6363

etc/config.xml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
33
xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Store:etc/config.xsd">
44
<default>
5-
<corsRequests>
6-
<general>
5+
<web>
6+
<corsRequests>
77
<origin_url>*</origin_url>
88
<allow_credentials>0</allow_credentials>
9-
</general>
10-
</corsRequests>
9+
</corsRequests>
10+
</web>
1111
</default>
1212
</config>

0 commit comments

Comments
 (0)