fix null vs undefined