mirror of
https://github.com/zulip/zulip.git
synced 2025-11-16 03:41:58 +00:00
dialog_widget: Fix implicit use of any.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
committed by
Tim Abbott
parent
e9d0e43668
commit
2e9b313333
@@ -161,9 +161,13 @@ export function launch(conf: DialogWidgetConfig): void {
|
||||
$inputs.each(function () {
|
||||
const property_name = $(this).attr("name")!;
|
||||
if (property_name) {
|
||||
if ($(this).is("input[type='file']") && $(this).prop("files")?.length) {
|
||||
if (
|
||||
this instanceof HTMLInputElement &&
|
||||
this.type === "file" &&
|
||||
this.files?.length
|
||||
) {
|
||||
// If the input is a file input and a file has been selected, set value to file object
|
||||
current_values[property_name] = $(this).prop("files")[0];
|
||||
current_values[property_name] = this.files[0];
|
||||
} else if (property_name === "edit_bot_owner") {
|
||||
current_values[property_name] = $(this).find(".dropdown_widget_value").text();
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user