diff --git a/web/src/actors/header.rs b/web/src/actors/header.rs
index 442eba8..261fa06 100644
--- a/web/src/actors/header.rs
+++ b/web/src/actors/header.rs
@@ -1,6 +1,6 @@
use leptos::*;
use leptos_router::*;
-use crate::{getters::Getter, prelude::*, DEFAULT_AVATAR_URL};
+use crate::{getters::Getter, prelude::*, FALLBACK_IMAGE_URL};
use apb::{field::OptionalString, ActivityMut, Actor, Base, Object, ObjectMut};
@@ -34,8 +34,8 @@ pub fn ActorHeader() -> impl IntoView {
None => view! { "could not resolve user: "{e}
}.into_view(),
Some(Ok(actor)) => {
- let avatar_url = actor.icon().get().map(|x| x.url().id().str().unwrap_or(DEFAULT_AVATAR_URL.into())).unwrap_or(DEFAULT_AVATAR_URL.into());
- let background_url = actor.image().get().map(|x| x.url().id().str().unwrap_or(DEFAULT_AVATAR_URL.into())).unwrap_or(DEFAULT_AVATAR_URL.into());
+ let avatar_url = actor.icon().get().map(|x| x.url().id().str().unwrap_or(FALLBACK_IMAGE_URL.into())).unwrap_or(FALLBACK_IMAGE_URL.into());
+ let background_url = actor.image().get().map(|x| x.url().id().str().unwrap_or(FALLBACK_IMAGE_URL.into())).unwrap_or(FALLBACK_IMAGE_URL.into());
let username = actor.preferred_username().unwrap_or_default().to_string();
let name = actor.name().str().unwrap_or(username.clone());
let created = actor.published().ok();
diff --git a/web/src/components/user.rs b/web/src/components/user.rs
index 40121ea..4624713 100644
--- a/web/src/components/user.rs
+++ b/web/src/components/user.rs
@@ -1,5 +1,5 @@
use leptos::*;
-use crate::{prelude::*, DEFAULT_AVATAR_URL};
+use crate::{prelude::*, FALLBACK_IMAGE_URL};
use apb::{field::OptionalString, Activity, ActivityMut, Actor, Base, Object, ObjectMut};
@@ -12,10 +12,10 @@ pub fn ActorStrip(object: crate::Object) -> impl IntoView {
let actor_id = object.id().unwrap_or_default().to_string();
let username = object.preferred_username().unwrap_or_default().to_string();
let domain = object.id().unwrap_or_default().replace("https://", "").split('/').next().unwrap_or_default().to_string();
- let avatar = object.icon().get().map(|x| x.url().id().str().unwrap_or(DEFAULT_AVATAR_URL.into())).unwrap_or(DEFAULT_AVATAR_URL.into());
+ let avatar = object.icon().get().map(|x| x.url().id().str().unwrap_or(FALLBACK_IMAGE_URL.into())).unwrap_or(FALLBACK_IMAGE_URL.into());
view! {
- {username}@{domain}
+ {username}@{domain}
}
}
@@ -29,7 +29,7 @@ pub fn ActorBanner(object: crate::Object) -> impl IntoView {
serde_json::Value::Object(_) => {
let uid = object.id().unwrap_or_default().to_string();
let uri = Uri::web(U::Actor, &uid);
- let avatar_url = object.icon().get().map(|x| x.url().id().str().unwrap_or(DEFAULT_AVATAR_URL.into())).unwrap_or(DEFAULT_AVATAR_URL.into());
+ let avatar_url = object.icon().get().map(|x| x.url().id().str().unwrap_or(FALLBACK_IMAGE_URL.into())).unwrap_or(FALLBACK_IMAGE_URL.into());
let username = object.preferred_username().unwrap_or_default().to_string();
let domain = object.id().unwrap_or_default().replace("https://", "").split('/').next().unwrap_or_default().to_string();
let display_name = object.name().unwrap_or_default().to_string();
@@ -37,7 +37,7 @@ pub fn ActorBanner(object: crate::Object) -> impl IntoView {