# HG changeset patch # User luca_milaz # Date 1756990272 0 # Node ID da4f5f4a9046d55a88f41a32cc1b41fb6ccf1011 # Parent 1fd4e4e93c85b41f937295c8dd2e5aae3320b0a6 Uploaded diff -r 1fd4e4e93c85 -r da4f5f4a9046 COBRAxy/utils/general_utils.py --- a/COBRAxy/utils/general_utils.py Thu Sep 04 12:40:01 2025 +0000 +++ b/COBRAxy/utils/general_utils.py Thu Sep 04 12:51:12 2025 +0000 @@ -82,7 +82,12 @@ if hasattr(self, '_original_extension') and self._original_extension: return self._original_extension - # TODO: fix, it's the dumb pickle thing keep this behaviour if we are not dealing with XML or JSON + # For XML and JSON without original extension, use the base extension + if self == FileFormat.XML: + return "xml" + elif self == FileFormat.JSON: + return "json" + return self.value[-1] class FilePath():