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

Commit 75c2f17

Browse files
committed
fix(NgModel): Read the view value in the flush phase
This code was originally authored by @mhevery in the DirectiveInjector change.
1 parent 6f3587d commit 75c2f17

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/directive/ng_model_select.dart

+3-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,9 @@ class InputSelect implements AttachAware {
5050
_model.watchCollection = true;
5151
_mode = new _MultipleSelectionMode(expando, _selectElement, _model);
5252
}
53-
_mode.onModelChange(_model.viewValue);
53+
_scope.rootScope.domRead(() {
54+
_mode.onModelChange(_model.viewValue);
55+
});
5456
});
5557

5658
_selectElement.onChange.listen((event) => _mode.onViewChange(event));

0 commit comments

Comments
 (0)