but callbacks registered in the if block (if any) may not have run yet