Verify that the name is a string, if not use the ID, fix #3845