Skip to content

Commit ed6f0c8

Browse files
committed
fix: fix favicon.ico bug
1 parent 6a3c15b commit ed6f0c8

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

src/server/setting.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ export default class Setting extends Model {
3131
}
3232

3333
async uploadFavicon(filePath: string) {
34-
const faviconPath = path.join(this.appDir, 'output/favicon.ico')
34+
const faviconPath = path.join(this.appDir, 'favicon.ico')
3535
fse.copySync(filePath, faviconPath)
3636
}
3737

src/views/theme/includes/FaviconSetting.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ export default class FaviconSetting extends Vue {
4646
faviconPath = ''
4747
4848
mounted() {
49-
this.faviconPath = path.join('file://', this.site.appDir, 'output', `favicon.ico?a=${Math.random()}`)
49+
this.faviconPath = path.join('file://', this.site.appDir, `favicon.ico?a=${Math.random()}`)
5050
}
5151
5252
beforeUpload(file: any) {
@@ -72,7 +72,7 @@ export default class FaviconSetting extends Vue {
7272
ipcRenderer.once('favicon-uploaded', (event: IpcRendererEvent, result: any) => {
7373
this.file = null
7474
this.$bus.$emit('site-reload')
75-
this.faviconPath = path.join('file://', this.site.appDir, 'output', `favicon.ico?a=${Math.random()}`)
75+
this.faviconPath = path.join('file://', this.site.appDir, `favicon.ico?a=${Math.random()}`)
7676
this.$message.success(this.$t('faviconSettingSuccess'))
7777
})
7878
}

0 commit comments

Comments
 (0)