| 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; |