Skip to content

Commit

Permalink
Fix issue with favicon configuration (#32)
Browse files Browse the repository at this point in the history
  • Loading branch information
stefandesu committed Jul 9, 2024
1 parent a1f896a commit ef53640
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions config/config.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,13 @@ if (await exists(configFile)) {
}

// Symlink favicon
const faviconFile = await exists("config/_current/favicon.ico") ? "../config/_current/favicon.ico" : "favicon-default.ico"
await fs.rm("public/favicon.ico")
await fs.symlink(faviconFile, "public/favicon.ico")
const faviconFile = await exists("config/_current/favicon.ico") ? "../config/_current/favicon.ico" : "favicon-default.ico", faviconTarget = "public/favicon.ico"
try {
await fs.rm(faviconTarget)
} catch (error) {
// ignore
}
await fs.symlink(faviconFile, faviconTarget)

import { readFile } from "node:fs/promises"
const fileUrl = new URL("../package.json", import.meta.url)
Expand Down

0 comments on commit ef53640

Please sign in to comment.