MCPcopy
hub / github.com/iptv-org/iptv / validate

Method validate

scripts/models/stream.ts:26–33  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

24 }
25
26 validate(): Collection<Error> {
27 const errors = new Collection<Error>()
28 if (!isURI(this.url)) {
29 errors.add(new Error(`The stream URL "${this.url}" is invalid`))
30 }
31
32 return errors
33 }
34
35 updateWithIssue(dataSet: DataSet): this {
36 const streamId = dataSet.getString('stream_id') || ''

Callers 2

addStreamFunction · 0.95
editStreamFunction · 0.80

Calls 1

isURIFunction · 0.90

Tested by

no test coverage detected