Skip to content

Commit

Permalink
fix: map NoAccessValue on API
Browse files Browse the repository at this point in the history
  • Loading branch information
GAlexIHU committed Nov 11, 2024
1 parent c59941c commit 5309ca5
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions openmeter/entitlement/driver/parser.go
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,10 @@ func MapEntitlementValueToAPI(entitlementValue entitlement.EntitlementValue) (ap
return api.EntitlementValue{
HasAccess: ent.HasAccess(),
}, nil
case *entitlement.NoAccessValue:
return api.EntitlementValue{
HasAccess: false,
}, nil
default:
return api.EntitlementValue{}, errors.New("unknown entitlement type")
}
Expand Down

0 comments on commit 5309ca5

Please sign in to comment.