fix settings link
parent
6b87fc2485
commit
489db64055
|
@ -1,7 +1,8 @@
|
|||
'use strict';
|
||||
|
||||
document.addEventListener('DOMContentLoaded', event => {
|
||||
document.getElementById('logout').insertAdjacentHTML('beforebegin', `<a href="/admin/settings/">
|
||||
let link = document.querySelector('header > div:first-child a:first-child').getAttribute('href') + "/settings/"
|
||||
document.getElementById('logout').insertAdjacentHTML('beforebegin', `<a href="${link}">
|
||||
<div class="action">
|
||||
<i class="material-icons">settings</i>
|
||||
</div>
|
||||
|
|
2
hugo.go
2
hugo.go
|
@ -69,7 +69,7 @@ func (h Hugo) ServeHTTP(w http.ResponseWriter, r *http.Request) (int, error) {
|
|||
frontmatter = "toml"
|
||||
}
|
||||
|
||||
http.Redirect(w, r, h.Config.BaseURL+"/config."+frontmatter, http.StatusTemporaryRedirect)
|
||||
http.Redirect(w, r, h.FileManager.Configs[0].AbsoluteURL+"/config."+frontmatter, http.StatusTemporaryRedirect)
|
||||
return 0, nil
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue