mirror of
https://github.com/gurucomputing/headscale-ui.git
synced 2026-01-23 02:34:43 +00:00
fix foreach inside async
This commit is contained in:
parent
0001827897
commit
27ea256265
1 changed files with 3 additions and 3 deletions
|
|
@ -19,12 +19,12 @@
|
|||
appSettings.apiKeyList = (await response.json()).apiKeys;
|
||||
appSettings.apiTested = true;
|
||||
|
||||
// determine the remaining time for the key we are currently using. Note: Nested Async
|
||||
appSettings.apiKeyList.forEach((key) => {
|
||||
// determine the remaining time for the key we are currently using.
|
||||
for (const key of appSettings.apiKeyList) {
|
||||
if (persistentAppSettings.headscaleAPIKey.startsWith(key.prefix)) {
|
||||
getKeyRemainingTime(new Date(key.expiration));
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
} catch (error) {
|
||||
let message: string;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue