Skip to content
This repository was archived by the owner on Apr 20, 2018. It is now read-only.

Commit 2bbad15

Browse files
BehaviorSubject getValue() better to check for errors using .hasError field rather than checking .error field for null/undefined.
1 parent 7bc3ac2 commit 2bbad15

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/core/subjects/behaviorsubject.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343
*/
4444
getValue: function () {
4545
checkDisposed(this);
46-
if (this.error) {
46+
if (this.hasError) {
4747
throw this.error;
4848
}
4949
return this.value;

0 commit comments

Comments
 (0)