Skip to content

Commit

Permalink
Shorten code
Browse files Browse the repository at this point in the history
Co-authored-by: Brett M. Morris <[email protected]>
  • Loading branch information
pllim and bmorris3 committed Aug 10, 2023
1 parent 8a73691 commit 71738c0
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions jdaviz/core/region_translators.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,12 +57,7 @@ def _get_region_from_spatial_subset(plugin_obj, subset_state):
link_type = plugin_obj.app._jdaviz_helper.get_link_type(
subset_state.xatt.parent.label, plugin_obj.dataset_selected)

if link_type == 'wcs':
to_sky = True
else:
to_sky = False

return roi_subset_state_to_region(subset_state, to_sky=to_sky)
return roi_subset_state_to_region(subset_state, to_sky=(link_type == 'wcs'))


def regions2roi(region_shape, wcs=None):
Expand Down

0 comments on commit 71738c0

Please sign in to comment.