fix restore threads