Content deleted Content added
fix |
of course, old hour values |
||
Line 313:
if (elements[6] == ELEMENT_TIMEPERIOD) then -- '10:28:27 am'
if (numberOfElements == 6) then return checkAndOutput(nil, nil, nil, values[1] + periodHourAdd(values[6]), values[3], values[5]) end
possibleHour = values[1] + periodHourAdd(values[2]) -- hour now needs possible adjusting since we saw a time period
-- wasTime = true -- already set
i = 4 -- '10', ':', '28', ':', '27' and 'am' are six elements, so we start 4 further from 3
Line 320 ⟶ 321:
if (numberOfElements == 4) then return checkAndOutput(nil, nil, nil, values[1] + periodHourAdd(values[4]), values[3], nil) end
wasTime = true -- this is a valid final time, so we can check date appended to this
possibleHour = values[1] + periodHourAdd(values[2]) -- hour now needs possible adjusting since we saw a time period
i = 2 -- '10', ':', '28' and 'am' are four elements, so we start 2 further from 3
end
|