Skip to content

Commit

Permalink
fix: solve some formatting issues for image variables
Browse files Browse the repository at this point in the history
  • Loading branch information
nekofar committed Mar 7, 2024
1 parent 3a1a749 commit b0a4920
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/routes.rs
Original file line number Diff line number Diff line change
Expand Up @@ -307,15 +307,15 @@ pub async fn handle_fs_result<D>(req: Request, ctx: RouteContext<D>) -> worker::
_ => None,
};

let (image) = match (community, platform) {
let image = match (community, platform) {
(Some(LilNouns), Some(Ethereum)) => {
let image = req
.url()
.unwrap()
.join(format!("{}/og.png", sqid).as_str())
.unwrap()
.to_string();
(image)
image
}
(Some(LilNouns), Some(PropLot)) => {
let image = req
Expand All @@ -324,7 +324,7 @@ pub async fn handle_fs_result<D>(req: Request, ctx: RouteContext<D>) -> worker::
.join(format!("{}/og.png", sqid).as_str())
.unwrap()
.to_string();
(image)
image
}
(Some(LilNouns), Some(MetaGov)) => {
let image = req
Expand All @@ -333,9 +333,9 @@ pub async fn handle_fs_result<D>(req: Request, ctx: RouteContext<D>) -> worker::
.join(format!("{}/og.png", sqid).as_str())
.unwrap()
.to_string();
(image)
image
}
_ => (String::new()),
_ => String::new(),
};

let html_doc = format!(
Expand Down

0 comments on commit b0a4920

Please sign in to comment.