Revert "fixed logic"

This reverts commit aa8421c637d854fd9bc394a695dedc7c965d2864.