additional checks to skip invalid nodes