Commit 22dd7754 authored by 戚攀's avatar 戚攀
Browse files

Merge pull request !6 from WeidenthalerMatthias/fix.header_tofile

parents f48f7a61 9c67dc59
...@@ -4,7 +4,7 @@ from ..fsspec_fileobj import open_fileobj ...@@ -4,7 +4,7 @@ from ..fsspec_fileobj import open_fileobj
from ..s3_config import load_s3_options from ..s3_config import load_s3_options
def tofile(fits_header, out_path, s3_options=load_s3_options(), *args, **kwargs): def tofile(fits_header, out_path, s3_options=load_s3_options(), *args, **kwargs):
fileobj = open_fileobj(out_path, s3_options) fileobj = open_fileobj(out_path, s3_options, mode='wb')
fits_header.tofile(fileobj, *args, **kwargs) fits_header.tofile(fileobj, *args, **kwargs)
if hasattr(fileobj, 'close'): if hasattr(fileobj, 'close'):
fileobj.close() fileobj.close()
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment