Still a some optimizing that could be done.