Skip to content

Commit

Permalink
Removing extension from file name, and using explicitly the ext field. (
Browse files Browse the repository at this point in the history
  • Loading branch information
germa89 authored Aug 18, 2023
1 parent 5566cc2 commit d0a42b9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/ansys/mapdl/core/mapdl_grpc.py
Original file line number Diff line number Diff line change
Expand Up @@ -3036,8 +3036,9 @@ def file(self, fname: str = "", ext: str = "", **kwargs) -> str:
fname = self._get_file_name(fname, ext, "cdb")
fname = self._get_file_path(fname, kwargs.get("progress_bar", False))
file_, ext_, _ = self._decompose_fname(fname)
fname = fname[: -len(ext_) - 1] # Removing extension. -1 for the dot.
if self._local:
return self._file(filename=fname, **kwargs)
return self._file(filename=fname, extension=ext_, **kwargs)
else:
return self._file(filename=file_, extension=ext_)

Expand Down

0 comments on commit d0a42b9

Please sign in to comment.