mirror of
https://github.com/davidjohnbarton/crawler-google-places.git
synced 2025-12-12 08:28:46 +00:00
Updated places extractor
This commit is contained in:
parent
d0bea52177
commit
ce135fb8e8
|
|
@ -46,7 +46,7 @@ const extractPlaceDetail = async (page) => {
|
|||
// Finds values from y axis
|
||||
$(this).find('.section-popular-times-bar').each(function (barIndex) {
|
||||
const occupancyMatch = $(this).attr('aria-label').match(/\d+\s+?%/);
|
||||
if (occupancyMatch) {
|
||||
if (occupancyMatch && occupancyMatch.length) {
|
||||
const maybeHour = graphStartFromHour + barIndex;
|
||||
graphs[day].push({
|
||||
hour: maybeHour > 24 ? maybeHour - 24 : maybeHour,
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user