spiele editierbar

This commit is contained in:
Klaas 2024-05-28 15:33:59 +02:00
parent 0561a59ac2
commit e8c9d2574f
2 changed files with 3 additions and 3 deletions

2
app.js
View File

@ -589,7 +589,7 @@ app.get('/login', (req, res) => {
});
app.get('/register', (req, res) => {
res.render('register'); // Stelle sicher, dass es eine register.ejs gibt
res.render('register', {session: req.session}); // Stelle sicher, dass es eine register.ejs gibt
});
app.get('/spiele', async (req, res) => {

View File

@ -16,7 +16,7 @@
<div class="collapse navbar-collapse" id="navbarNav">
<ul class="navbar-nav">
<% if (session && ( session.role =='admin' || session.role =='user' )) { %>
<% if (session) { if ( session.role =='admin' || session.role =='user' ) { %>
<li class="nav-item">
<a class="nav-link" href="/">Trainings</a>
@ -31,7 +31,7 @@
<a class="nav-link" href="/profile">Profil</a>
</li>
<% } %>
<% }} %>
<li class="nav-item">
<a class="nav-link" href="/spiele">Spiele</a>