Skip to content

Commit

Permalink
fix: Change GMail fake openings userAgent filter
Browse files Browse the repository at this point in the history
  • Loading branch information
diego3g committed Aug 11, 2021
1 parent 101f606 commit 6f9a5e7
Showing 1 changed file with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,14 @@ export class RegisterEventController implements Controller {
const type = eventTypesMap[data.eventType]
const meta = data[eventMetaMap[data.eventType]]

if (type === 'OPEN' && meta?.userAgent?.includes('GoogleImageProxy')) {
/**
* Filter false GMail openings
*/
if (
type === 'OPEN' &&
meta?.userAgent ===
'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.135 Safari/537.36 Edge/12.246 Mozilla/5.0'
) {
return ok()
}

Expand Down

0 comments on commit 6f9a5e7

Please sign in to comment.