This commit is contained in:
@@ -256,7 +256,14 @@ function getAuthHeaders() {
|
||||
|
||||
async function loadPools() {
|
||||
try {
|
||||
const res = await fetch('/api/v1/pools', { headers: getAuthHeaders() });
|
||||
// Add cache-busting to ensure fresh data
|
||||
const res = await fetch('/api/v1/pools?_=' + Date.now(), {
|
||||
headers: {
|
||||
...getAuthHeaders(),
|
||||
'Cache-Control': 'no-cache',
|
||||
'Pragma': 'no-cache'
|
||||
}
|
||||
});
|
||||
const data = await res.json().catch(() => null);
|
||||
const listEl = document.getElementById('pools-list');
|
||||
|
||||
@@ -621,7 +628,9 @@ async function deletePool(name) {
|
||||
});
|
||||
|
||||
if (res.ok) {
|
||||
loadPools();
|
||||
// Wait a moment for the deletion to fully complete, then refresh
|
||||
await new Promise(resolve => setTimeout(resolve, 500));
|
||||
await loadPools();
|
||||
alert('Pool deleted successfully');
|
||||
} else {
|
||||
const err = await res.json();
|
||||
|
||||
Reference in New Issue
Block a user