Raising 400 error instead of setting status