You are, for two reasons. First, subs fire or submerge before anything else fires, unless there is an enemy destroyer in the battle. Second, air units can’t hit subs unless there’s a destroyer friendly to the air units in the battle. So, in the case of only air units attacking only subs, the subs can submerge before the air units fire, but even if they don’t the air units can’t hit them.