Skip to content

Commit 7376520

Browse files
Improve Filter Example to Block Anonymous Traffic
The removed piece of code is not necessary as `null` and `""` are both considered to be 0 bytes which is what the `length()` function checks for. A customer also reported unusual behavior when using the deleted line.
1 parent 40fc435 commit 7376520

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/connections/destinations/destination-filters.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ Use the [Public API](https://docs.segmentapis.com/tag/Destination-Filters/){:tar
124124
"destinationId": "<DESTIANTION_ID>",
125125
"title": "Don't send event if userId is null",
126126
"description": "Drop event if there is no userId on the request",
127-
"if": "length( userId ) < 1 or typeof( userId ) != 'string'",
127+
"if": "length( userId ) < 1",
128128
"actions": [
129129
{
130130
"type": "DROP"

0 commit comments

Comments
 (0)