Add currentUser template func
This commit is contained in:
@@ -16,12 +16,15 @@
|
||||
<a class="text-base font-semibold hover:text-blue-100 pr-8" href="/faq">FAQ</a>
|
||||
</div>
|
||||
<div class="space-x-4">
|
||||
{{if currentUser }}
|
||||
<form action="/signout" method="post" class="inline pr-4">
|
||||
{{csrfField}}
|
||||
<button type="submit">Sign out</button>
|
||||
</form>
|
||||
{{else}}
|
||||
<a href="/signin">Sign in</a>
|
||||
<a href="/signup" clss="px-4 py-2 bg-blue-700 hover:bg-blue-600 rounded">Sign up</a>
|
||||
{{end}}
|
||||
</div>
|
||||
</nav>
|
||||
</header>
|
||||
|
||||
Reference in New Issue
Block a user