As the more or less annual flu epidemics since 1918 demonstrate, viruses don't care about economics. But in the case of Covid-19, not-capitalist China deceived the world about it for weeks, weeks that could have been used to try to limit spread and prepare to treat and create vaccines against the disease.
OTOH, capitalism - getting profit by providing a needed product or service - provides far greater incentive to produce things like treatments and vaccines than does government compulsion or bureaucracy, the alternative to capitalism.