Skip to content

Commit

Permalink
Merge pull request #269 from a0eoc/dashboard-for-mods
Browse files Browse the repository at this point in the history
Little fixes
  • Loading branch information
vednoc authored Sep 26, 2023
2 parents bf86cec + 9940e11 commit 257aa9a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion modules/database/init/init.go
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ func seed() {
defer log.Info.Println("Finished seeding mock data.")

pw := func(s string) string {
s, err := util.HashPassword("admin123")
s, err := util.HashPassword(s)
if err != nil {
log.Warn.Fatal(err)
}
Expand Down
4 changes: 3 additions & 1 deletion web/views/partials/sidebar.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,10 @@
{{ if .User }}
<li><a href="/user/{{ .User.Username }}">{{ template "icons/user" }} Profile</a></li>
<li><a href="/account">{{ template "icons/settings" }} Settings</a></li>
{{ if .User.IsAdmin }}
{{ if .User.IsModOrAdmin }}
<li><a href="/dashboard">{{ template "icons/pie-chart" }} Dashboard</a></li>
{{ end }}
{{ if .User.IsAdmin }}
<li><a href="/monitor">{{ template "icons/gauge" }} Monitor</a></li>
{{ end }}
<li><a href="/logout">{{ template "icons/log-out" }} Log out</a></li>
Expand Down

0 comments on commit 257aa9a

Please sign in to comment.