Fixing metadata endpoint. (#4257)

This commit is contained in:
Dessalines 2023-12-13 04:50:51 -05:00 committed by GitHub
parent 5ad881f3df
commit 93d123b46e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,4 +1,4 @@
use actix_web::web::{Data, Json};
use actix_web::web::{Data, Json, Query};
use lemmy_api_common::{
context::LemmyContext,
post::{GetSiteMetadata, GetSiteMetadataResponse},
@ -8,7 +8,7 @@ use lemmy_utils::error::LemmyError;
#[tracing::instrument(skip(context))]
pub async fn get_link_metadata(
data: Json<GetSiteMetadata>,
data: Query<GetSiteMetadata>,
context: Data<LemmyContext>,
) -> Result<Json<GetSiteMetadataResponse>, LemmyError> {
let metadata = fetch_site_metadata(context.client(), &data.url).await?;