Fix config API to return data directly instead of wrapped in config object
This commit is contained in:
@@ -505,7 +505,7 @@ const loadConfig = async () => {
|
||||
isLoading.value = true
|
||||
try {
|
||||
const response = await $fetch('/api/config')
|
||||
config.value = response.config
|
||||
config.value = response
|
||||
} catch (error) {
|
||||
errorMessage.value = 'Fehler beim Laden der Konfiguration.'
|
||||
} finally {
|
||||
@@ -521,7 +521,7 @@ const saveConfig = async () => {
|
||||
try {
|
||||
await $fetch('/api/config', {
|
||||
method: 'PUT',
|
||||
body: { config: config.value }
|
||||
body: config.value
|
||||
})
|
||||
|
||||
successMessage.value = 'Konfiguration erfolgreich gespeichert!'
|
||||
|
||||
Reference in New Issue
Block a user