fix: error handling
This commit is contained in:
@@ -678,7 +678,12 @@ export const getSelectors = async (page: Page, coordinates: Coordinates) => {
|
|||||||
}
|
}
|
||||||
}, { x: coordinates.x, y: coordinates.y });
|
}, { x: coordinates.x, y: coordinates.y });
|
||||||
return selectors;
|
return selectors;
|
||||||
}
|
} catch (e) {
|
||||||
|
const { message, stack } = e as Error;
|
||||||
|
logger.log('error', `Error while retrieving element: ${message}`);
|
||||||
|
logger.log('error', `Stack: ${stack}`);
|
||||||
|
}
|
||||||
|
return null;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user