support undefined and null