MCPcopy
hub / github.com/tc39/proposal-observable / next

Function next

src/Observable.js:144–168  ·  view source on GitHub ↗
(value)

Source from the content-addressed store, hash-verified

142 },
143
144 next(value) {
145
146 let subscription = this._subscription;
147
148 // If the stream if closed, then return undefined
149 if (subscriptionClosed(subscription))
150 return undefined;
151
152 let observer = subscription._observer;
153
154 try {
155 let m = getMethod(observer, "next");
156
157 // If the observer doesn't support "next", then return undefined
158 if (!m)
159 return undefined;
160
161 // Send the next value to the sink
162 m.call(observer, value);
163 }
164 catch(e) {
165 // HostReportErrors(e);
166 }
167 return undefined;
168 },
169
170 error(value) {
171

Callers

nothing calls this directly

Calls 2

subscriptionClosedFunction · 0.85
getMethodFunction · 0.85

Tested by

no test coverage detected