fixing null case missing