What just happened? Tesla is facing a lawsuit filed by two former employees over claims its decision to lay off around 10% of its workforce violated federal law as the company did not provide those affected with advanced notice of the cuts.

Reuters writes that the employees from its Sparks, Nevada, Gigafactory filed the suit in Texas on Sunday. It states that 500 employees were terminated from the factory without giving a 60-day notice period---a violation of the Worker Adjustment and Retraining Notification (WARN) Act.

John Lynch and Daxton Hartsfield, who had worked at the plant for around five years, were among the those let go from the factory this month, according to the suit. They say neither were given advanced notice of their terminations, on June 10 and June 15, respectively, and are now seeking class-action status on behalf of any US Tesla employees laid off in May or June who also received no advanced notice.

The WARN Act requires companies to provide a 60-day notice period to workers before any layoffs affecting 50 more employees, giving them enough time to find other employment or retrain.

"Tesla started laying people off in blatant disregard for the WARN act," Boston-based employment attorney Shannon Liss-Riordan, who is representing the workers, told Bloomberg.

Earlier this month, Tesla boss Elon Musk told executives he wanted to cut 10% of jobs at the company and pause all hiring over his "super bad feeling" about the economy. He clarified to CNBC that the figure represents salaried workers only, while the number of hourly employees will increase. However, this still means around 3.5% of Tesla's total workforce is being laid off, an amount he said is "not super material."

"A year from now, I think our headcount will be higher in both salaried and obviously in hourly," Musk added.

The world's richest person also addressed the lawsuit, saying it had "no standing" and was a "small lawsuit of minor consequence."

Elsewhere in the interview, Musk said he believed a recession was "inevitable at some point," and that it happening in the near term is "more likely than not" but "not a certainty."

Musk previously came under fire for demanding Tesla and SpaceX workers spend a minimum of 40 hours in the office per week or quit. He also said that staff must work in a main company office, not a remote location.