diff --git a/btrfs_explorer/src/http_chunk.rs b/btrfs_explorer/src/http_chunk.rs index f0d342b..5951dbb 100644 --- a/btrfs_explorer/src/http_chunk.rs +++ b/btrfs_explorer/src/http_chunk.rs @@ -1,7 +1,7 @@ use maud::{Markup, html}; use rouille::{Request, Response}; use crate::{ - btrfs_lookup::Tree, btrfs_structs::{self, BlockRef, ItemType, TreeID, Value}, key, main_error::MainError, render_common::{render_page, size_name} + btrfs_lookup::Tree, btrfs_structs::{self, BlockRef, ItemType, TreeID, Value}, key, main_error::MainError, render_common::{render_page, size_name, http_path} }; struct ChunkLineDisplay { @@ -221,8 +221,11 @@ fn render_allchunks(data: Vec) -> Markup { } span.itemvalue { @if bg.link { - a href=(format!("/chunk/{:x}", bg.logical_address.unwrap())) { (bg.description) } ", " (size_name(bg.size)) - + a href=(format!("{}/chunk/{:x}", http_path(), bg.logical_address.unwrap())) { + (bg.description) + } + ", " + (size_name(bg.size)) } @else { (bg.description) ", " (size_name(bg.size)) }