mirror of
https://github.com/karl0ss/homepage.git
synced 2025-05-06 15:23:40 +01:00
fix path.join import
This commit is contained in:
parent
cf39395924
commit
939f5d7c20
@ -1,4 +1,4 @@
|
|||||||
import { join, path } from "path";
|
import { join } from "path";
|
||||||
import { existsSync, copyFile, promises as fs } from "fs";
|
import { existsSync, copyFile, promises as fs } from "fs";
|
||||||
import yaml from "js-yaml";
|
import yaml from "js-yaml";
|
||||||
|
|
||||||
@ -19,7 +19,7 @@ export default function checkAndCopyConfig(config) {
|
|||||||
export async function getSettings() {
|
export async function getSettings() {
|
||||||
checkAndCopyConfig("settings.yaml");
|
checkAndCopyConfig("settings.yaml");
|
||||||
|
|
||||||
const settingsYaml = path.join(process.cwd(), "config", "settings.yaml");
|
const settingsYaml = join(process.cwd(), "config", "settings.yaml");
|
||||||
const fileContents = await fs.readFile(settingsYaml, "utf8");
|
const fileContents = await fs.readFile(settingsYaml, "utf8");
|
||||||
return yaml.load(fileContents);
|
return yaml.load(fileContents);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user