Skip to content

Commit

Permalink
lint: use function instead of redundant closure
Browse files Browse the repository at this point in the history
  • Loading branch information
johnbchron committed Mar 9, 2024
1 parent 2e9d529 commit 7a4b7ab
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions crates/site-app/src/components/photo.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,8 @@ pub fn Photo(
#[prop(default = "rounded-box")] rounded: &'static str,
#[prop(default = "")] extra_class: &'static str,
) -> impl IntoView {
let photo = create_resource(
move || (),
move |_| bl::fetch::fetch_photo_thumbnail(photo_id),
);
let photo =
create_resource(move || photo_id, bl::fetch::fetch_photo_thumbnail);

view! {
<Suspense fallback=|| view!{ }>
Expand Down

0 comments on commit 7a4b7ab

Please sign in to comment.