More validation

Cleans up validation codebase a bit. Shouldn't have any breaking changes for production.