swap places of mounted and pending update checks

prevents a type error if the component isn't mounted
This commit is contained in:
Igor Scekic
2015-08-13 16:34:47 +02:00
parent 530a30c1d5
commit 0e834fabca
@@ -22,7 +22,7 @@ var valueContextKey =
'__ReactDOMSelect_value$' + Math.random().toString(36).slice(2);
function updateOptionsIfPendingUpdateAndMounted() {
if (this._wrapperState.pendingUpdate && this._rootNodeID) {
if (this._rootNodeID && this._wrapperState.pendingUpdate) {
this._wrapperState.pendingUpdate = false;
var props = this._currentElement.props;