Skip to content

Commit

Permalink
fix filepress
Browse files Browse the repository at this point in the history
  • Loading branch information
mnsrulz committed Apr 9, 2023
1 parent 659e892 commit 2f4151a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/libs/filepress.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export class FilepressResolver extends BaseUrlResolver {
const workingUrl = initialResponse.url;
const parsedUrl = new URL(workingUrl);
const fileId = parsedUrl.pathname.split('/').pop();
const apiResponse = await this.gotInstance.post(`https://api.${parsedUrl.hostname}/api/file/downlaod/`, {
const apiResponse = await this.gotInstance.post(`https://${parsedUrl.hostname}/api/file/downlaod/`, {
json: {
id: fileId,
method: "publicDownlaod"
Expand All @@ -24,7 +24,7 @@ export class FilepressResolver extends BaseUrlResolver {
"referer": workingUrl
}
}).json<{ data: string }>();

if (apiResponse.data) {
const gdResolver = new gDriveV2Resolver();
const gdurl = `https://drive.google.com/file/d/${apiResponse.data}/view`;
Expand Down

0 comments on commit 2f4151a

Please sign in to comment.