Skip to content

Commit e49d05b

Browse files
authored
Merge pull request #144 from unsignedapps/bok/flagwigwag.value
Added FlagWigwag.value getter
2 parents 938572d + ed908ed commit e49d05b

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Sources/Vexil/Observability/FlagWigwag.swift

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,11 @@ public struct FlagWigwag<Output>: Sendable where Output: FlagValue {
3939
/// The default value for this flag
4040
public let defaultValue: Output
4141

42+
/// The current resolved value of this flag
43+
public var value: Output {
44+
lookup.value(for: keyPath) ?? defaultValue
45+
}
46+
4247
/// A human readable name for the flag. Only visible in flag editors like Vexillographer.
4348
public let name: String
4449

0 commit comments

Comments
 (0)