Apple says it has fixed a bug that caused dozens of apps downloaded from its App Store to crash earlier this week.

The company said late Thursday that the glitch was caused by a server that was generating faulty digital rights management (DRM) code for some applications download from its iOS and Mac app stores.

It did not say how many users were affected but said those who experienced problems should download a new update of the affected apps using the updates function in the App Store or iTunes.

That means users don't have to delete the corrupted version of the app and risk losing data, developer Marco Arment pointed out on his blog, marco.org.

It was Arment who first spotted the app problem late Tuesday when after the release of the latest update to his Instapaper app, he was deluged with emails and tweets froms customers complaining that the app was crashing on launch.

He traced the problem to a corrupt update being distributed by the App Store and began tracking which other applications were experiencing similar problems.

Arment said about 20,000 customers of his Instapaper app were affected and that he knew of at least 120 other apps affected, including popular ones such as Angry Birds, GoodReader, Yahoo, Huffington Post and the L.A. Times.

As a result of the bug, some of the affected apps were getting bad user reviews. Those reviews will not show up on the fixed version of the apps.

Apple said the problem lasted only for one day and affected a small number of users although Arment and other developers said the number of users affected was more significant than Apple suggested.