Skip to content

Commit

Permalink
Fix missing static keyword (#28)
Browse files Browse the repository at this point in the history
  • Loading branch information
ktoso authored Nov 7, 2022
1 parent 2db9e9d commit d0a4929
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Sources/InstrumentationBaggage/Baggage.swift
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ extension Baggage {
/// To access the task-local value, use `Baggage.current`.
///
/// SeeAlso: [Swift Task Locals](https://developer.apple.com/documentation/swift/tasklocal)
func withValue<T>(_ value: Baggage?, operation: () throws -> T) rethrows -> T {
public static func withValue<T>(_ value: Baggage?, operation: () throws -> T) rethrows -> T {
try Baggage.$current.withValue(value, operation: operation)
}

Expand All @@ -251,7 +251,7 @@ extension Baggage {
/// To access the task-local value, use `Baggage.current`.
///
/// SeeAlso: [Swift Task Locals](https://developer.apple.com/documentation/swift/tasklocal)
func withValue<T>(_ value: Baggage?, operation: () async throws -> T) async rethrows -> T {
public static func withValue<T>(_ value: Baggage?, operation: () async throws -> T) async rethrows -> T {
try await Baggage.$current.withValue(value, operation: operation)
}
}
Expand Down

0 comments on commit d0a4929

Please sign in to comment.