add null check for predelete