Skip to content

Commit

Permalink
fix: Make HookContext properties public (#45)
Browse files Browse the repository at this point in the history
## This PR
- When writing a custom hook I notice that we cannot read the
`HookContext` properties.
- This PR is making all the `HookContext` properties public.

Signed-off-by: Thomas Poignant <[email protected]>
Co-authored-by: Nicklas Lundin <[email protected]>
  • Loading branch information
thomaspoignant and nicklasl authored Jul 8, 2024
1 parent 7256a3c commit 003bbb6
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions Sources/OpenFeature/HookContext.swift
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@ import Foundation

/// A data struct to hold immutable context that ``Hook`` instances use.
public struct HookContext<T> {
var flagKey: String
var type: FlagValueType
var defaultValue: T
var ctx: EvaluationContext?
var clientMetadata: ClientMetadata?
var providerMetadata: ProviderMetadata?
public var flagKey: String
public var type: FlagValueType
public var defaultValue: T
public var ctx: EvaluationContext?
public var clientMetadata: ClientMetadata?
public var providerMetadata: ProviderMetadata?
}

0 comments on commit 003bbb6

Please sign in to comment.