The Department sorting function is working now.