Skip to content

Conversation

@conormurray95
Copy link
Contributor

@conormurray95 conormurray95 commented Oct 12, 2022

Issue
If a flag existed with variationMap rules in which a target rule existed but no segment rule existed we would get a nil pointer error dereferencing the TargetSegments object.

Fix
Check that the objects are not nil before we try and dereference them
I'm also opening a ticket to deprecate this converter code, we should be able to expose the Evaluator object from the go sdk and use it directly so we can use the one unified rest.FeatureConfig model for everything going forward

@swarmia
Copy link

swarmia bot commented Oct 12, 2022

Copy link
Contributor

@jcox250 jcox250 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good

@conormurray95 conormurray95 merged commit 1d253c4 into main Oct 12, 2022
@conormurray95 conormurray95 deleted the FFM-4719-nil-pointer-error branch October 25, 2022 21:11
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.

2 participants