mirror of
https://github.com/ajnart/homarr.git
synced 2025-11-16 02:06:21 +01:00
🚧 wip migrate to next-i18n
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import path from 'path';
|
||||
import fs from 'fs';
|
||||
|
||||
export function getConfig(name: string) {
|
||||
export function getConfig(name: string, props: any = undefined) {
|
||||
// Check if the config file exists
|
||||
const configPath = path.join(process.cwd(), 'data/configs', `${name}.json`);
|
||||
if (!fs.existsSync(configPath)) {
|
||||
@@ -30,6 +30,7 @@ export function getConfig(name: string) {
|
||||
props: {
|
||||
configName: name,
|
||||
config: JSON.parse(config),
|
||||
...props,
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user