Fixed null reference error
Fixed null reference error