📅  最后修改于: 2022-03-11 15:03:18.107000             🧑  作者: Mango
//To make sure that .toString() or .toUpperCase() doesn't throw an error,
you could:
string = "" + string; // amends the value to an string, even if its undefined or null etc
//instead of:
string = string.toString();