Skip to content

Commit

Permalink
fix: try fix deploy workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
Panakotta00 committed Jul 20, 2024
1 parent 824d099 commit 347c879
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Website/src/util.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ pub enum URLOrFile {
}

pub async fn read_file_or_url(url: &str) -> Option<URLOrFile> {
Some(if let Ok(url) = Url::parse(url) {
let response = reqwest::get(url).await.map_err(|e| error!("Failed to request '{url}': {e}")).ok()?;
Some(if let Ok(url_str) = Url::parse(url) {
let response = reqwest::get(url_str).await.map_err(|e| error!("Failed to request '{url}': {e}")).ok()?;
if response.status() != StatusCode::OK {
return None
}
Expand Down

0 comments on commit 347c879

Please sign in to comment.