| Index: chrome/renderer/resources/extensions/sync_file_system_custom_bindings.js
|
| diff --git a/chrome/renderer/resources/extensions/sync_file_system_custom_bindings.js b/chrome/renderer/resources/extensions/sync_file_system_custom_bindings.js
|
| index bcb121931316192e5ba2a794bf6052929670aec2..ae904421e254ba78a16225dcd7126f2c12ee7041 100644
|
| --- a/chrome/renderer/resources/extensions/sync_file_system_custom_bindings.js
|
| +++ b/chrome/renderer/resources/extensions/sync_file_system_custom_bindings.js
|
| @@ -8,32 +8,31 @@ var binding = require('binding').Binding.create('syncFileSystem');
|
|
|
| var chromeHidden = requireNative('chrome_hidden').GetChromeHidden();
|
| var fileSystemNatives = requireNative('file_system_natives');
|
| +var forEach = require('utils').forEach;
|
| var syncFileSystemNatives = requireNative('sync_file_system');
|
|
|
| binding.registerCustomHook(function(bindingsAPI) {
|
| var apiFunctions = bindingsAPI.apiFunctions;
|
|
|
| // Functions which take in an [instanceOf=FileEntry].
|
| - function bindFileEntryFunction(functionName) {
|
| + function bindFileEntryFunction(i, functionName) {
|
| apiFunctions.setUpdateArgumentsPostValidate(
|
| functionName, function(entry, callback) {
|
| var fileSystemUrl = entry.toURL();
|
| return [fileSystemUrl, callback];
|
| });
|
| }
|
| - ['getFileStatus']
|
| - .forEach(bindFileEntryFunction);
|
| + forEach(['getFileStatus'], bindFileEntryFunction);
|
|
|
| // Functions which take in an [instanceOf=DOMFileSystem].
|
| - function bindFileSystemFunction(functionName) {
|
| + function bindFileSystemFunction(i, functionName) {
|
| apiFunctions.setUpdateArgumentsPostValidate(
|
| functionName, function(filesystem, callback) {
|
| var fileSystemUrl = filesystem.root.toURL();
|
| return [fileSystemUrl, callback];
|
| });
|
| }
|
| - ['deleteFileSystem', 'getUsageAndQuota']
|
| - .forEach(bindFileSystemFunction);
|
| + forEach(['deleteFileSystem', 'getUsageAndQuota'], bindFileSystemFunction);
|
|
|
| // Functions which return an [instanceOf=DOMFileSystem].
|
| apiFunctions.setCustomCallback('requestFileSystem',
|
|
|