Fixed bug introduced by premature optimization

This was possibility was taken into account, the code fix was in
comments.