mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2026-01-10 01:22:31 -06:00
WebUI: Replace getElements & getChildren
This PR further reduces Mootools usage. PR #22220.
This commit is contained in:
@@ -2102,7 +2102,8 @@ Use ';' to split multiple entries. Can use wildcard '*'.)QBT_TR[CONTEXT=OptionsD
|
||||
|
||||
// Advanced Tab
|
||||
const updateNetworkInterfaces = (default_iface, default_iface_name) => {
|
||||
$("networkInterface").getChildren().each(c => c.destroy());
|
||||
[...document.getElementById("networkInterface").children].forEach((el) => { el.destroy(); });
|
||||
|
||||
fetch("api/v2/app/networkInterfaceList", {
|
||||
method: "GET",
|
||||
cache: "no-store"
|
||||
@@ -2130,7 +2131,8 @@ Use ';' to split multiple entries. Can use wildcard '*'.)QBT_TR[CONTEXT=OptionsD
|
||||
};
|
||||
|
||||
const updateInterfaceAddresses = (iface, default_addr) => {
|
||||
$("optionalIPAddressToBind").getChildren().each(c => c.destroy());
|
||||
[...document.getElementById("optionalIPAddressToBind").children].forEach((el) => { el.destroy(); });
|
||||
|
||||
const url = new URL("api/v2/app/networkInterfaceAddressList", window.location);
|
||||
url.search = new URLSearchParams({
|
||||
iface: iface
|
||||
|
||||
Reference in New Issue
Block a user