changed default constructor to have data set to nullptr