update domain registration and dns frontend

This commit is contained in:
2026-05-14 16:50:53 -04:00
parent 83f29b5047
commit 0adc180198
2 changed files with 3 additions and 5 deletions
+1 -1
View File
@@ -33,7 +33,7 @@ async function RegisterNewDomain(domain) {
if (!prefix) throw new Error("Invalid domain");
const key = `${prefix}`;
const value = JSON.stringify({ type: 'A', host: '10.66.66.1' });
const value = JSON.stringify({ type: 'A', host: '10.66.66.1', ttl: '300' });
await client.put(key).value(value);
}
+2 -4
View File
@@ -28,13 +28,11 @@ router.get('/dns/edit/:domainId', authMw.AllowIfAuthenticated, async (req, res,
const fullDomain = result.domain + "." + result.tld;
const rawRecords = await GetAllRecords(fullDomain);
let records = [];
let recordHeaders = ["Domain"];
let recordHeaders = [];
for(const [key, value] of Object.entries(rawRecords)) {
let parsedVal = JSON.parse(value);
let finalRecord = {
domain: CoreDNSToDomain(key)
};
let finalRecord = {};
for(const [key, value] of Object.entries(parsedVal)) {
if(!recordHeaders.includes(key)) {