Novage / p2p-media-loader

An open-source engine for P2P streaming of live and on demand video directly in a web browser HTML page
https://novage.com.ua/p2p-media-loader/demo.html
Apache License 2.0
1.41k stars 311 forks source link

Feat: Segment validation #336

Closed DimaDemchenko closed 6 months ago

DimaDemchenko commented 6 months ago

Closes https://github.com/Novage/p2p-private-issues/issues/5 Closes #337

mrlika commented 6 months ago

Closes https://github.com/Novage/p2p-private-issues/issues/5

DimaDemchenko commented 6 months ago

If validation of segment returns false, app throws an exception from file loader.ts

private throwErrorIfNotLoadingStatus() { if (this._status !== "loading") { throw new Error(Request has been already ${this.status}.); } }