From 5ac60d24c877ae65a553cb7a7666de380a7108a6 Mon Sep 17 00:00:00 2001 From: Aku Kotkavuo Date: Thu, 30 Jul 2026 03:31:37 +0300 Subject: [PATCH] Use datname as og:title --- src/routes/disc_view.rs | 3 +++ templates/disc_view.html | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/routes/disc_view.rs b/src/routes/disc_view.rs index e5cfaa0..66e7645 100644 --- a/src/routes/disc_view.rs +++ b/src/routes/disc_view.rs @@ -79,6 +79,7 @@ struct DiscViewTemplate { can_view_history: bool, disc_id: i32, title: String, + base_rom_name: String, system_name: String, system_code: String, media_type: String, @@ -694,6 +695,7 @@ async fn disc_view( }, detail.disc.filename_suffix.as_deref(), ), + base_rom_name: rom_base_name, system_name: detail.system.system_name(), system_code: detail.system.code.clone(), media_type: detail.disc.media_type.to_string(), @@ -1719,6 +1721,7 @@ mod tests { can_view_history: false, disc_id: 1, title: "Example Disc".to_string(), + base_rom_name: "Example Disc (USA)".to_string(), system_name: "Sony - PlayStation 3".to_string(), system_code: "PS3".to_string(), media_type: "Blu-ray Disc".to_string(), diff --git a/templates/disc_view.html b/templates/disc_view.html index 6ebf757..ed4f90c 100644 --- a/templates/disc_view.html +++ b/templates/disc_view.html @@ -1,6 +1,6 @@ {% extends "base.html" %} -{% block title %}{{ title }}{% endblock %} +{% block title %}{{ base_rom_name }}{% endblock %} {% block description %}{{ system_name }} - {{ media_type }}{% endblock %} {% block content %}