Revert "optmizations"

This reverts commit b71a43c8c3449175316808c6ef27fe7a587a89d6.