Fixed occupancy sel

This commit is contained in:
drobnikj 2019-01-08 12:37:50 +01:00
parent 22bf467992
commit 84b4040a0b

View File

@ -45,7 +45,7 @@ const extractPlaceDetail = async (page) => {
}); });
// Finds values from y axis // Finds values from y axis
$(this).find('.section-popular-times-bar').each(function (barIndex) { $(this).find('.section-popular-times-bar').each(function (barIndex) {
const occupancyMatch = $(this).attr('aria-label').match(/\d+\s+?%/); const occupancyMatch = $(this).attr('aria-label').match(/\d+(\s+)?%/);
if (occupancyMatch && occupancyMatch.length) { if (occupancyMatch && occupancyMatch.length) {
const maybeHour = graphStartFromHour + barIndex; const maybeHour = graphStartFromHour + barIndex;
graphs[day].push({ graphs[day].push({