* Adds the provided identifier to the pack. * @param {string} identifier identifier
(identifier)
| 158 | * @param {string} identifier identifier |
| 159 | */ |
| 160 | _addRequest(identifier) { |
| 161 | this.requests.push(identifier); |
| 162 | if (this.requestsTimeout === undefined) { |
| 163 | this.requestsTimeout = setTimeout(() => { |
| 164 | this.requests.push(undefined); |
| 165 | this.requestsTimeout = undefined; |
| 166 | }, MAX_TIME_IN_FRESH_PACK); |
| 167 | if (this.requestsTimeout.unref) this.requestsTimeout.unref(); |
| 168 | } |
| 169 | } |
| 170 | |
| 171 | stopCapturingRequests() { |
| 172 | if (this.requestsTimeout !== undefined) { |