fix null value exception