Update To 11.40.268.0
[platform/framework/web/crosswalk.git] / src / third_party / WebKit / LayoutTests / http / tests / serviceworker / resources / fetch-access-control-worker.js
index 56b8b8a..07b594f 100644 (file)
@@ -37,7 +37,7 @@ function getRequestInit(params) {
     init['credentials'] = params['credentials'];
   }
   if (params['headers'] === 'CUSTOM') {
-    init['headers'] = {"X-ServiceWorker-Test": "test"};
+    init['headers'] = {'X-ServiceWorker-Test': 'test'};
   } else if (params['headers'] === '{}') {
     init['headers'] = {};
   }
@@ -46,9 +46,9 @@ function getRequestInit(params) {
 
 function headersToArray(headers) {
   var ret = [];
-  headers.forEach(function(value, key) {
-      ret.push([key, value]);
-    });
+  for (var header of headers) {
+    ret.push(header);
+  }
   return ret;
 }