Skip to content

Commit

Permalink
Merge branch 'map_ndcube_migration' of github.com:sunpy/sunpy into pr…
Browse files Browse the repository at this point in the history
…/7603
  • Loading branch information
nabobalis committed May 8, 2024
2 parents 4806c9b + 6c37fbd commit e7b733d
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions sunpy/map/mapbase.py
Original file line number Diff line number Diff line change
Expand Up @@ -224,6 +224,11 @@ def __init__(self, data, *, wcs=None, uncertainty=None, mask=None, meta,
super().__init__(data, wcs=None, uncertainty=uncertainty, mask=mask,
meta=MetaDict(meta), unit=unit, copy=copy,
**ndcube_kwargs)
# NDData.__init__ sets self.wcs before it sets self.meta as our wcs
# setter needs self.meta to exist we call the parent __init__ with
# wcs=None and then set self.wcs so that meta is already set before the
# wcs setter is run with the "real" wcs.
self.wcs = wcs

# Validate header
# TODO: This should be a function of the header, not of the map
Expand Down

0 comments on commit e7b733d

Please sign in to comment.