Senior living and long-term care pharmacy company Omnicare will pay $8 million to settle allegations that its use of a prescription verification system resulted in the submission of false claims for Medicare and Medicaid reimbursement, the Department of Justice announced Tuesday.

The automated label verification system, used in some of Omnicare’s hub pharmacy locations from 2008 through 2014, employed a drug code that was less specific than the National Drug Code. “This in turn caused Omnicare’s automated system to approve the dispensing of certain generic drugs in more than 2 million transactions where the drug actually dispensed was made by a different manufacturer and had a different NDC than the drug initially identified by the pharmacist to be dispensed,” according to the settlement agreement.

The false manufacturer and NDC information on the labels and within Omnicare’s electronic dispensing information affected the company’s ability to properly track and, if necessary, conduct resident-level recalls of drugs, the government said.

“Ensuring accuracy in the dispensing of and billing for medication in the Medicare Part D and Medicaid programs, especially to long-term care patients, is vital to public safety,” Acting U.S. Attorney William E. Fitzpatrick said in the announcement.

Omnicare denies the allegations, according to the settlement, but the parties involved agreed to settle “to avoid the delay, uncertainty, inconvenience and expense of protracted litigation.”

The lawsuit was filed by two former Omnicare pharmacists, each of whom will receive more than $2 million for their actions as “whistleblowers.”