aesthetic at best
extracted code validation bit