Skip to content

Commit

Permalink
Filter out events from GPTBot
Browse files Browse the repository at this point in the history
  • Loading branch information
robbie-c committed Aug 15, 2023
1 parent e69e488 commit cc2e2c9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -467,7 +467,7 @@ export const _utf8Encode = function (string: string): string {
// sending false capturing data
export const _isBlockedUA = function (ua: string): boolean {
if (
/(google web preview|baiduspider|yandexbot|bingbot|googlebot|yahoo! slurp|ahrefsbot|facebookexternalhit|facebookcatalog|applebot|semrushbot|duckduckbot|twitterbot|rogerbot|linkedinbot|mj12bot|sitebulb|bot.htm|bot.php|hubspot|crawler|prerender)/i.test(
/(google web preview|baiduspider|yandexbot|bingbot|googlebot|yahoo! slurp|ahrefsbot|facebookexternalhit|facebookcatalog|applebot|semrushbot|duckduckbot|twitterbot|rogerbot|linkedinbot|mj12bot|sitebulb|bot.htm|bot.php|hubspot|crawler|prerender|gptbot)/i.test(
ua
)
) {
Expand Down

0 comments on commit cc2e2c9

Please sign in to comment.