MCPcopy Index your code
hub / github.com/MALSync/MALSync / getNextPage

Function getNextPage

src/_provider/listAbstract.ts:127–146  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

125 }
126
127 async getNextPage(): Promise<listElement[]> {
128 if (this.done) return this.templist;
129
130 if (
131 this.modes.frontend &&
132 this.status === 1 &&
133 ['default', 'unread', 'latest_release'].includes(this.sort)
134 ) {
135 this.modes.sortAiring = true;
136 return this.getCompleteList();
137 }
138
139 await this.getNext();
140
141 if (this.modes.cached) this.getCache().setValue(this.templist.slice(0, 24));
142
143 this.firstLoaded = true;
144
145 return this.templist;
146 }
147
148 private async getNext() {
149 this.loading = true;

Callers

nothing calls this directly

Calls 2

setValueMethod · 0.80
getCacheMethod · 0.45

Tested by

no test coverage detected