Adding in precautionary code