loading and saving fixes