Skip to content

Fix inaccurate segment GAID validation pattern#79

Open
mattpolicastro wants to merge 2 commits intojdeboer:devfrom
mattpolicastro:dev
Open

Fix inaccurate segment GAID validation pattern#79
mattpolicastro wants to merge 2 commits intojdeboer:devfrom
mattpolicastro:dev

Conversation

@mattpolicastro
Copy link
Copy Markdown

Segments created in the native Google Analytics segment builder are automatically assigned GAIDs; these GAIDs are usually alphanumeric but I've noticed that underscores and dashes are beginning to be used as valid characters. However, these IDs will trigger a hard error:

Error in validObject(.Object) :
  invalid class "gaSegmentId" object: gaSegmentId must match the regular expression ^gaid::\-?[0-9A-Za-z]+$

I've amended the regex pattern used to validate the GAIDs to not fail on dashes or underscores.

Image 2021-09-28 at 1 01 31 PM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant