From b36fc74915c899a8fec1a1f315bf4c77cc2f45d4 Mon Sep 17 00:00:00 2001 From: Michael Lane Date: Mon, 20 Sep 2021 01:11:57 +0000 Subject: [PATCH] 782: Replaced the literal strings 'x_axis_label' and 'y_axis_label' in the query_params submitted to xarray with the values for the axis labels stored in self._coverage_properties. --- pygeoapi/provider/xarray_.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pygeoapi/provider/xarray_.py b/pygeoapi/provider/xarray_.py index d0327e1..84bc8ae 100644 --- a/pygeoapi/provider/xarray_.py +++ b/pygeoapi/provider/xarray_.py @@ -231,8 +231,8 @@ class XarrayProvider(BaseProvider): LOGGER.warning(msg) raise ProviderQueryError(msg) else: - query_params['x_axis_label'] = slice(bbox[0], bbox[2]) - query_params['y_axis_label'] = slice(bbox[1], bbox[3]) + query_params[self._coverage_properties['x_axis_label']] = slice(bbox[0], bbox[2]) + query_params[self._coverage_properties['y_axis_label']] = slice(bbox[1], bbox[3]) if datetime_ is not None: if self._coverage_properties['time_axis_label'] in subsets: