LUN-1152: file content needs to be saved before changing location