Skip to content

Commit

Permalink
Remove if-let without an assignment for Swift 5.6 compatability
Browse files Browse the repository at this point in the history
  • Loading branch information
exPHAT committed Jul 24, 2023
1 parent 563acf6 commit f760488
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Sources/SwiftWhisper/WhisperParams.swift
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public class WhisperParams {
}

deinit {
if let _language {
if let _language = _language {
free(_language)
}
}
Expand All @@ -30,7 +30,7 @@ public class WhisperParams {
set {
guard let pointer = strdup(newValue.rawValue) else { return }

if let _language {
if let _language = _language {
free(_language) // Free previous reference since we're creating a new one
}

Expand Down

0 comments on commit f760488

Please sign in to comment.