issues with null value error