change nesting check