replaced nullptr with 0