(
hash: ManifestHash,
debugName: string = 'lookupVersionByHash',
)
| 780 | } |
| 781 | |
| 782 | private lookupVersionByHash( |
| 783 | hash: ManifestHash, |
| 784 | debugName: string = 'lookupVersionByHash', |
| 785 | ): AppVersion { |
| 786 | // The version should exist, but check just in case. |
| 787 | if (!this.versions.has(hash)) { |
| 788 | throw new Error( |
| 789 | `Invariant violated (${debugName}): want AppVersion for ${hash} but not loaded`, |
| 790 | ); |
| 791 | } |
| 792 | return this.versions.get(hash)!; |
| 793 | } |
| 794 | |
| 795 | /** |
| 796 | * Decide which version of the manifest to use for the event. |
no test coverage detected