Removed debugging statements, moved boolean.