added a check for the name argument to be a string in NameBot class