Police department earns accreditation