Fix subspeciality null pointer issue