1
0
Fork 0
forked from alemi/upub

fix(web): uri pretty len check mismatch

This commit is contained in:
əlemi 2024-07-03 06:34:29 +02:00
parent 9c2cbf2303
commit 6c88dec148
Signed by: alemi
GPG key ID: A4895B84D311642C

View file

@ -206,7 +206,7 @@ impl Uri {
pub fn pretty(url: &str) -> String {
let bare = url.replace("https://", "");
if url.len() < 50 {
if bare.len() < 50 {
bare
} else {
format!("{}..", bare.get(..50).unwrap_or_default())