Merge "Issue #1791 Fix problems in SmartScript when there is no data." into omaha_13.3.1

Former-commit-id: d612495967 [formerly 807d8773ad] [formerly f3fd91c311] [formerly c895ee60fa [formerly f3fd91c311 [formerly a12ccd946a59dae45a4b5b754655d8eef7a56a29]]]
Former-commit-id: c895ee60fa
Former-commit-id: d25e380bfd45fba9e5ddfb52706b916c9ca113fd [formerly 5701030750]
Former-commit-id: 30bd797879
This commit is contained in:
Nate Jensen 2013-03-26 16:15:27 -05:00 committed by Gerrit Code Review
commit 55572918b3

View file

@ -440,13 +440,13 @@ class SmartScript(BaseTool.BaseTool):
if timeRangeList is not None:
retVal = {}
for i in xrange(len(timeRangeList)):
iresult = self._getGridsResult(timeRangeList[i], noDataError, mode, result[i])
iresult = self._getGridsResult(timeRangeList[i], noDataError, mode, exprName, result[i])
retVal[timeRangeList[i]] = iresult
return retVal
else:
return self._getGridsResult(timeRange, noDataError, mode, result)
return self._getGridsResult(timeRange, noDataError, mode, exprName, result)
def _getGridsResult(self, timeRange, noDataError, mode, result):
def _getGridsResult(self, timeRange, noDataError, mode, exprName, result):
retVal = None
if result is not None:
if len(result) == 0: