Updated

Swedish Prime Minister Stefan Lofven has shaken up his Cabinet after opposition parties said they would file a no-confidence vote in three government ministers over one of the largest security breaches in the country.

Lofven says two ministers will leave of their own accord but that Defense Minister Peter Hultqvist will remain in the Cabinet.

Describing the opposition motion as "hasty and ill-planned," Lofven told reporters Thursday that he did not want to be responsible for a government crisis.

He said that now "it's up to the Parliament."

It was not immediately clear if the opposition parties would change their no-confidence motion against Hultqvist.

The 2015 breach allowed IT workers abroad to access confidential information in Sweden's government and police database.