Skip to content

Commit

Permalink
馃悰 Fix default home path Promise
Browse files Browse the repository at this point in the history
  • Loading branch information
AnandChowdhary committed Mar 26, 2020
1 parent 34c2591 commit 8626960
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/files.ts
Expand Up @@ -64,11 +64,11 @@ export const getHomePath = async () => {
if (config.homePath) return config.homePath;
let file: string | undefined = undefined;
file = join(contentDir, "index.md");
if (safeReadFile(file)) return file;
if (await safeReadFile(file)) return file;
file = join(contentDir, "README.md");
if (safeReadFile(file)) return file;
if (await safeReadFile(file)) return file;
file = join(contentDir, "..", "README.md");
if (safeReadFile(file)) return file;
if (await safeReadFile(file)) return file;
return join("..", "src", "index.md");
};

Expand Down

0 comments on commit 8626960

Please sign in to comment.