validate departments