To put it simply:
-- Whether or not you contract covid has nothing to do with whether or not you wear a mask. Nothing.
AND
-- Carrying a mask in your pocket offers precisely the same level of protection from transmission of a respiratory virus as it does if you wear it on your face. That is, it offers NO protection.
A mask offers no protection from a virus, as everybody knows. Maybe a sneeze directly onto you, but most people try not to do that.
Washing your hands and not touching your face was, in any case, the best way to protect against the dread “droplet contamination” of items. And even in that case, viruses survive virtually no time at all outside of their hosts.
Bacteria is a whole different matter, but this is not a bacteria.