diff --git a/pyproject.toml b/pyproject.toml index b7701ad..2145a7a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "ssb-konjunk" -version = "0.1.6" +version = "0.1.7" description = "SSB Konjunk" authors = ["Edvard Garmannslund "] license = "MIT" diff --git a/src/ssb_konjunk/saving.py b/src/ssb_konjunk/saving.py index d61bcb3..57eec6d 100644 --- a/src/ssb_konjunk/saving.py +++ b/src/ssb_konjunk/saving.py @@ -323,9 +323,10 @@ def write_ssb_file( # Find version number/decide whether to overwrite or make new version. version_number = _find_version_number(files, stable_version) - file_path = f"{file_path}_v{version_number}.{filetype}" + if version_number: + file_path = f"{file_path}_v{version_number}.{filetype}" - _save_df(df, file_path, filetype, fs, seperator, encoding) + _save_df(df, file_path, filetype, fs, seperator, encoding) def read_ssb_file(