Completed
Push — master ( 1310e2...1a152a )
by
unknown
11s
created
api/v1/index.php 1 patch
Braces   +6 added lines, -3 removed lines patch added patch discarded remove patch
@@ -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.