Showing
4 changed files
with
4 additions
and
12 deletions
| @@ -105,9 +105,7 @@ mixin RxObjectMixin<T> on NotifyManager<T> { | @@ -105,9 +105,7 @@ mixin RxObjectMixin<T> on NotifyManager<T> { | ||
| 105 | 105 | ||
| 106 | /// Returns the current [value] | 106 | /// Returns the current [value] |
| 107 | T get value { | 107 | T get value { |
| 108 | - if (RxInterface.proxy != null) { | ||
| 109 | - RxInterface.proxy!.addListener(subject); | ||
| 110 | - } | 108 | + RxInterface.proxy?.addListener(subject); |
| 111 | return _value; | 109 | return _value; |
| 112 | } | 110 | } |
| 113 | 111 |
| @@ -78,9 +78,7 @@ class RxList<E> extends ListMixin<E> | @@ -78,9 +78,7 @@ class RxList<E> extends ListMixin<E> | ||
| 78 | @override | 78 | @override |
| 79 | @protected | 79 | @protected |
| 80 | List<E> get value { | 80 | List<E> get value { |
| 81 | - if (RxInterface.proxy != null) { | ||
| 82 | - RxInterface.proxy!.addListener(subject); | ||
| 83 | - } | 81 | + RxInterface.proxy?.addListener(subject); |
| 84 | return _value; | 82 | return _value; |
| 85 | } | 83 | } |
| 86 | 84 |
| @@ -56,9 +56,7 @@ class RxMap<K, V> extends MapMixin<K, V> | @@ -56,9 +56,7 @@ class RxMap<K, V> extends MapMixin<K, V> | ||
| 56 | @override | 56 | @override |
| 57 | @protected | 57 | @protected |
| 58 | Map<K, V> get value { | 58 | Map<K, V> get value { |
| 59 | - if (RxInterface.proxy != null) { | ||
| 60 | - RxInterface.proxy!.addListener(subject); | ||
| 61 | - } | 59 | + RxInterface.proxy?.addListener(subject); |
| 62 | return _value; | 60 | return _value; |
| 63 | } | 61 | } |
| 64 | } | 62 | } |
| @@ -23,9 +23,7 @@ class RxSet<E> extends SetMixin<E> | @@ -23,9 +23,7 @@ class RxSet<E> extends SetMixin<E> | ||
| 23 | @override | 23 | @override |
| 24 | @protected | 24 | @protected |
| 25 | Set<E> get value { | 25 | Set<E> get value { |
| 26 | - if (RxInterface.proxy != null) { | ||
| 27 | - RxInterface.proxy!.addListener(subject); | ||
| 28 | - } | 26 | + RxInterface.proxy?.addListener(subject); |
| 29 | return _value; | 27 | return _value; |
| 30 | } | 28 | } |
| 31 | 29 |
-
Please register or login to post a comment