mirror of
https://github.com/mendableai/firecrawl.git
synced 2024-11-16 11:42:24 +08:00
Update scrape.ts
This commit is contained in:
parent
7ae195bacc
commit
e1af815f8c
|
@ -65,8 +65,9 @@ export async function scrapeHelper(
|
|||
return { success: true, error: "No page found", returnCode: 200, data: docs[0] };
|
||||
}
|
||||
|
||||
// Remove rawHtml if pageOptions.rawHtml is false
|
||||
if (!pageOptions.includeRawHtml) {
|
||||
|
||||
// Remove rawHtml if pageOptions.rawHtml is false and extractorOptions.mode is llm-extraction-from-raw-html
|
||||
if (!pageOptions.includeRawHtml && extractorOptions.mode == "llm-extraction-from-raw-html") {
|
||||
filteredDocs.forEach(doc => {
|
||||
delete doc.rawHtml;
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue
Block a user