fuck the wizard too, what is he gonna do? magic?

This commit is contained in:
2026-07-02 13:45:55 +02:00
parent dc8ece6034
commit f84567425b
5 changed files with 1 additions and 634 deletions
+1 -52
View File
@@ -34,28 +34,7 @@ router.get('/', (req, res) => {
const noPlugins = req.query.noPlugins === 'true';
if (configExists() === false) {
let serialPorts;
SerialPort.list().then((deviceList) => {
serialPorts = deviceList.map(port => ({
path: port.path,
friendlyName: port.friendlyName,
}));
parseAudioDevice((result) => {
res.render('wizard', { // Magical utility wizard
isAdminAuthenticated: true,
videoDevices: result.audioDevices,
audioDevices: result.videoDevices,
serialPorts: serialPorts,
tunerProfiles: tunerProfiles.map((profile) => ({
id: profile.id,
label: profile.label,
detailsHtml: helpers.parseMarkdown(profile.details || '')
}))
});
});
});
res.status(500).send("not configured");
} else {
res.render('index', {
isAdminAuthenticated: helpers.isAdmin(req),
@@ -90,36 +69,6 @@ router.get('/403', (req, res) => {
router.get('/audioonly', (req, res) => res.render('audioonly'))
router.get('/wizard', (req, res) => {
let serialPorts;
if(!helpers.isAdmin(req)) {
res.render('login');
return;
}
SerialPort.list().then((deviceList) => {
serialPorts = deviceList.map(port => ({
path: port.path,
friendlyName: port.friendlyName,
}));
parseAudioDevice((result) => {
res.render('wizard', {
isAdminAuthenticated: helpers.isAdmin(req),
videoDevices: result.audioDevices,
audioDevices: result.videoDevices,
serialPorts: serialPorts,
tunerProfiles: tunerProfiles.map((profile) => ({
id: profile.id,
label: profile.label,
detailsHtml: helpers.parseMarkdown(profile.details || '')
}))
});
});
})
})
router.get('/setup', (req, res) => {
let serialPorts;
function loadConfig() {