|
@@ -12,9 +12,12 @@ |
|
|
block discarded – undo |
|
12
|
12
|
$settings->getGlobalSetting('secure_url', 'https://secure.burningflipside.com') |
|
13
|
13
|
); |
|
14
|
14
|
|
|
15
|
|
-if (isset($_SERVER['HTTP_ORIGIN']) && $_SERVER['HTTP_ORIGIN'] != '') { |
|
16
|
|
- foreach ($allowedOrigins as $allowedOrigin) { |
|
17
|
|
- if (preg_match('#' . $allowedOrigin . '#', $_SERVER['HTTP_ORIGIN'])) { |
|
|
15
|
+if (isset($_SERVER['HTTP_ORIGIN']) && $_SERVER['HTTP_ORIGIN'] != '') |
|
|
16
|
+{ |
|
|
17
|
+ foreach ($allowedOrigins as $allowedOrigin) |
|
|
18
|
+ { |
|
|
19
|
+ if (preg_match('#' . $allowedOrigin . '#', $_SERVER['HTTP_ORIGIN'])) |
|
|
20
|
+ { |
|
18
|
21
|
header('Access-Control-Allow-Origin: ' . $_SERVER['HTTP_ORIGIN']); |
|
19
|
22
|
header('Access-Control-Allow-Methods: GET, PUT, POST, DELETE, OPTIONS'); |
|
20
|
23
|
header('Access-Control-Allow-Credentials: true'); |
Please login to merge, or discard this patch.