DRY sanitize_input