mirror of
https://github.com/lifegpc/eh-downloader.git
synced 2026-06-06 05:38:44 +08:00
Add non-MPV mode support
This commit is contained in:
11
client.ts
11
client.ts
@@ -94,10 +94,17 @@ export class Client {
|
||||
* @param gid Gallery ID
|
||||
* @param page_token Page token
|
||||
* @param index Page index
|
||||
* @param nl Reload token
|
||||
* @returns
|
||||
*/
|
||||
async fetchSignlePage(gid: number, page_token: string, index: number) {
|
||||
const url = `https://${this.host}/s/${page_token}/${gid}-${index}`;
|
||||
async fetchSignlePage(
|
||||
gid: number,
|
||||
page_token: string,
|
||||
index: number,
|
||||
nl?: string,
|
||||
) {
|
||||
const p = nl ? `?nl=${nl}` : "";
|
||||
const url = `https://${this.host}/s/${page_token}/${gid}-${index}${p}`;
|
||||
const re = await this.get(url);
|
||||
if (re.status != 200) {
|
||||
throw new Error(
|
||||
|
||||
Reference in New Issue
Block a user