Streamlined validation.js