Fixed newData check in example