mirror of
https://github.com/netbox-community/netbox.git
synced 2025-08-24 08:25:17 -06:00
optimeze ts-ignore
This commit is contained in:
parent
47a86744c9
commit
9ada356950
@ -41,13 +41,12 @@ function initWindow(): void {
|
||||
const documentForms = document.forms
|
||||
for (var documentForm of documentForms) {
|
||||
if (documentForm.method.toUpperCase() == 'GET') {
|
||||
// @ts-ignore: // formdata is not yet supported by TS https://github.com/microsoft/TypeScript/issues/36217
|
||||
// @ts-ignore: Our version of typescript seems to be too old for FormDataEvent
|
||||
documentForm.addEventListener('formdata', function(event) {
|
||||
// @ts-ignore: // formdata is not yet supported by TS https://github.com/microsoft/TypeScript/issues/36217
|
||||
let formData = event.formData;
|
||||
// @ts-ignore: // formdata is not yet supported by TS https://github.com/microsoft/TypeScript/issues/36217
|
||||
for (let [name, value] of Array.from(formData.entries())) {
|
||||
// @ts-ignore: // formdata is not yet supported by TS https://github.com/microsoft/TypeScript/issues/36217
|
||||
// @ts-ignore: Our version of typescript seems to be too old for FormDataEvent
|
||||
let formData = event.formData;
|
||||
// @ts-ignore: Our version of typescript seems to be too old for FormDataEvent
|
||||
for (let [name, value] of Array.from(formData.entries())) {
|
||||
if (value === '') formData.delete(name);
|
||||
}
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user