The loopback address is often used as a point of significance in IP networks, providing router identifiers and other lynchpins that are not dependent on any single physical interface. Accidental deletion or deletion of the loopback address can cause significant disruption, so commit script logic to prevent that is welcome.
In our commit script, we perform two checks. First of all we could check that the number of IP addresses configured on the Lo0.0 interface is non-zero. Then we check that there is no attempt to disable either the main loopback interface, or the logical unit 0 interface.