trying to properly saving file