make sure contract name is not null