Fixed #2260: _removeByComponent method have bad "if"
Merge pull request #2261 from dingpinglv/Iss2260_removeByComponent

Fixed #2260: _removeByComponent method have bad "if"