Skip to content

Commit

Permalink
v2.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
GeoffreyChen777 committed Sep 19, 2022
1 parent af2c1ee commit c0b420d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions app/repositories/scraper-repository/scrapers/scraper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,20 +71,20 @@ export class Scraper implements ScraperType {

async function scrapeImpl(
this: ScraperType,
entityDraft: PaperEntity,
paperEntityDraft: PaperEntity,
force = false
): Promise<PaperEntity> {
const { scrapeURL, headers, enable } = this.preProcess(
entityDraft
paperEntityDraft
) as ScraperRequestType;

if (enable || force) {
const response = (await window.networkTool.get(
scrapeURL,
headers
)) as Response<string>;
return this.parsingProcess(response, entityDraft) as PaperEntity;
return this.parsingProcess(response, paperEntityDraft) as PaperEntity;
} else {
return entityDraft;
return paperEntityDraft;
}
}

0 comments on commit c0b420d

Please sign in to comment.