mirror of
https://github.com/0xMassi/webclaw.git
synced 2026-06-07 22:15:12 +02:00
fix: collapse nested if to satisfy clippy
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
b92c0ed186
commit
dff458d2f5
1 changed files with 4 additions and 4 deletions
|
|
@ -191,11 +191,11 @@ impl WebclawMcp {
|
||||||
async fn crawl(&self, Parameters(params): Parameters<CrawlParams>) -> Result<String, String> {
|
async fn crawl(&self, Parameters(params): Parameters<CrawlParams>) -> Result<String, String> {
|
||||||
validate_url(¶ms.url)?;
|
validate_url(¶ms.url)?;
|
||||||
|
|
||||||
if let Some(max) = params.max_pages {
|
if let Some(max) = params.max_pages
|
||||||
if max > 500 {
|
&& max > 500
|
||||||
|
{
|
||||||
return Err("max_pages cannot exceed 500".into());
|
return Err("max_pages cannot exceed 500".into());
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
let format = params.format.as_deref().unwrap_or("markdown");
|
let format = params.format.as_deref().unwrap_or("markdown");
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue