mirror of
https://github.com/kiddin9/op-packages.git
synced 2026-09-10 18:34:18 +08:00
🍓 Sync 2026-08-04 08:33:18
This commit is contained in:
@@ -7,7 +7,7 @@ include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=luci-app-passwall2
|
||||
PKG_VERSION:=26.7.16
|
||||
PKG_RELEASE:=66
|
||||
PKG_RELEASE:=67
|
||||
PKG_PO_VERSION:=$(PKG_VERSION)
|
||||
|
||||
PKG_CONFIG_DEPENDS:= \
|
||||
|
||||
@@ -205,7 +205,9 @@ gen_nftset() {
|
||||
nft "add set $NFTABLE_NAME $nftset_name { type $ip_type; flags interval, timeout; timeout $timeout_argument_set; gc-interval $gc_interval_time; auto-merge; }"
|
||||
fi
|
||||
fi
|
||||
[ $# -gt 0 ] || [ ! -t 0 ] && insert_nftset "$nftset_name" "$timeout_argument_element" "$@"
|
||||
if [ $# -gt 0 ]; then
|
||||
insert_nftset "$nftset_name" "$timeout_argument_element" "$@"
|
||||
fi
|
||||
}
|
||||
|
||||
gen_shunt_list() {
|
||||
|
||||
@@ -1214,7 +1214,7 @@ function getAssocListForNetwork(radioNet) {
|
||||
}));
|
||||
}
|
||||
|
||||
function getCachedAssocListForNetwork(radioNet) {
|
||||
function getCachedAssocListForNetwork(radioNet, waitForRefresh) {
|
||||
const key = radioNet.getName();
|
||||
|
||||
if (pendingAssocLists[key] == null) {
|
||||
@@ -1225,6 +1225,9 @@ function getCachedAssocListForNetwork(radioNet) {
|
||||
});
|
||||
}
|
||||
|
||||
if (waitForRefresh)
|
||||
return pendingAssocLists[key].then(() => cachedAssocLists[key] || []);
|
||||
|
||||
return Promise.resolve(cachedAssocLists[key] || []);
|
||||
}
|
||||
|
||||
@@ -4695,8 +4698,14 @@ return view.extend({
|
||||
};
|
||||
|
||||
return m.render().then(L.bind(function(m, nodes) {
|
||||
let initialAssocRefresh = true;
|
||||
|
||||
poll.add(L.bind(function() {
|
||||
const tasks = [ network.getHostHints(), network.getWifiDevices() ];
|
||||
const waitForAssocRefresh = initialAssocRefresh;
|
||||
const iwinfoResolverTask = areQcaRuntimeProbesSuspended()
|
||||
? Promise.resolve()
|
||||
: loadIwinfoResolver(false);
|
||||
|
||||
startIwinfoInfoRefresh();
|
||||
|
||||
@@ -4734,28 +4743,31 @@ return view.extend({
|
||||
});
|
||||
}, network))
|
||||
.then(L.bind(function(hosts_radios_wifis) {
|
||||
const tasks = [];
|
||||
const section = m?.children?.[0];
|
||||
return iwinfoResolverTask.then(() => {
|
||||
const tasks = [];
|
||||
const section = m?.children?.[0];
|
||||
|
||||
if (section != null) {
|
||||
section.radios = hosts_radios_wifis[1];
|
||||
section.wifis = hosts_radios_wifis[2];
|
||||
}
|
||||
|
||||
hosts_radios_wifis[2].forEach(hrw => tasks.push(getCachedAssocListForNetwork(hrw)) );
|
||||
|
||||
return Promise.all(tasks).then(function(data) {
|
||||
hosts_radios_wifis[3] = [];
|
||||
|
||||
for (let i = 0; i < data.length; i++) {
|
||||
const wifiNetwork = hosts_radios_wifis[2][i];
|
||||
const radioDev = hosts_radios_wifis[1].filter(function(d) { return d.getName() == wifiNetwork.getWifiDeviceName(); })[0];
|
||||
|
||||
for (let dy of data[i])
|
||||
hosts_radios_wifis[3].push(Object.assign({ radio: radioDev, network: wifiNetwork }, dy));
|
||||
if (section != null) {
|
||||
section.radios = hosts_radios_wifis[1];
|
||||
section.wifis = hosts_radios_wifis[2];
|
||||
}
|
||||
|
||||
return hosts_radios_wifis;
|
||||
hosts_radios_wifis[2].forEach(hrw => tasks.push(getCachedAssocListForNetwork(hrw, waitForAssocRefresh)) );
|
||||
|
||||
return Promise.all(tasks).then(function(data) {
|
||||
initialAssocRefresh = false;
|
||||
hosts_radios_wifis[3] = [];
|
||||
|
||||
for (let i = 0; i < data.length; i++) {
|
||||
const wifiNetwork = hosts_radios_wifis[2][i];
|
||||
const radioDev = hosts_radios_wifis[1].filter(function(d) { return d.getName() == wifiNetwork.getWifiDeviceName(); })[0];
|
||||
|
||||
for (let dy of data[i])
|
||||
hosts_radios_wifis[3].push(Object.assign({ radio: radioDev, network: wifiNetwork }, dy));
|
||||
}
|
||||
|
||||
return hosts_radios_wifis;
|
||||
});
|
||||
});
|
||||
}, network))
|
||||
.then(L.bind(function(zones, data) {
|
||||
|
||||
Reference in New Issue
Block a user