(win, opt_form)
| 14 | * @return {!FormDataWrapperInterface} |
| 15 | */ |
| 16 | export function createFormDataWrapper(win, opt_form) { |
| 17 | const platform = Services.platformFor(win); |
| 18 | |
| 19 | if (platform.isIos() && platform.getMajorVersion() == 11) { |
| 20 | return new Ios11NativeFormDataWrapper(opt_form); |
| 21 | } else if (FormData.prototype.entries && FormData.prototype.delete) { |
| 22 | return new NativeFormDataWrapper(opt_form); |
| 23 | } else { |
| 24 | return new PolyfillFormDataWrapper(opt_form); |
| 25 | } |
| 26 | } |
| 27 | |
| 28 | /** |
| 29 | * Check if the given object is a FormDataWrapper instance |
no test coverage detected