Tesla has been sued by two former employees claiming the automaker’s move to lay off roughly 10 per cent of its workforce has violated federal laws.

John Lynch and Daxton Hartsfield had worked at Tesla’s battery factory near Reno, Nevada for about five years each and were among more than 500 employees that were recently let go at the site. They claim that Tesla didn’t comply with the 60-day notification requirement under the Worker Adjustment and Retraining Notification Act (WARN Act) and are seeking class-action status on behalf of others who unexpectedly lost their jobs in May and June.

Read More: Elon Musk Tells Tesla Employees To Get Back To The Office Or Get Lost

In the lawsuit filed on Sunday in a federal court in Austin, Texas, Lynch says that he was notified on June 10 that he had been terminated, effective immediately, and that Hartsfield was notified on June 15 that he too had lost his job.

Speaking with Bloomberg, the employment attorney representing the workers, Shannon Liss-Riodan, said that “Tesla started laying people off in blatant disregard for the WARN act.”

Lynch and Hartsfield are seeking compensation and benefits for 60 days after their termination notices and also want Tesla to pay for attorneys’ fees and costs.

In early June, Tesla chief executive Elon Musk sent an email to company’s workforce that he wanted to get rid of one in 10 of the carmaker’s 100,000 employees around the world due to having a “super bad feeling” about the economy. This revelation came shortly after Musk instructed all Tesla workers to return to the office and stop remote work, noting that employees are required to spend a minimum of 40 hours in the office each week.

Curiously, while Tesla has cut hundreds of jobs, Musk claimed on Twitter on June 5 that the total headcount across the company would increase over the next 12 months, “but salaried [workers] should be fairly flat.”