McDonald's (MCD) - Get Report will pay $26 million and change a number of its workplace practices to settle a class-action lawsuit filed six years ago.

A number of McDonald's workers originally filed suit in three states, charging that the Chicago burger giant and certain of its franchisees underpaid workers, The Wall Street Journal reported.

The allegations included unpaid overtime and requiring the staff to buy and clean uniforms. Another allegation: A timekeeping system prevented workers from qualifying for overtime pay.

In the accord, McDonald's agreed to permit workers to leave their restaurants during their meal periods; it will no longer demand that workers take rest breaks only at the start of their shifts, and it promised to maintain detailed electronic time records and provide additional uniforms to crew members, the Journal reported.

McDonald's denied any wrongdoing. It said that it settled the suit even as it continued to believe that its employment practices complied with California labor law.