Merge commit 'bad6dab8e8c19c592961cc2a6bbed6b319adffaa'

# Conflicts:
#	src/game.rs
This commit is contained in:
Marie Birner
2025-08-02 20:20:22 +02:00
4 changed files with 486 additions and 4 deletions

View File

@@ -1,4 +1,4 @@
use crate::{page::new, Backend};
use crate::{page::new, random_names::get_name_by_uuid, Backend};
use axum::{
extract::{Path, State},
response::{IntoResponse, Redirect, Response},
@@ -41,7 +41,9 @@ async fn index(State(backend): State<Arc<Backend>>, cookies: CookieJar) -> Respo
(rank.rank)
}
@if rank.uuid == client.uuid { (PreEscaped("<mark>")) }
@if let Some(name) = rank.name { (name) } @else { "Anonymer Bär" }
@if let Some(name) = rank.name { (name) } @else {
"Anonymous "
(get_name_by_uuid(&rank.uuid))}
@if rank.uuid == client.uuid { (PreEscaped("</mark>")) }
}
span {