Skip to content

Commit

Permalink
chore(ios): resolve lint warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
autoreleasefool committed Aug 30, 2024
1 parent 9d3da47 commit b21504c
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 5 deletions.
3 changes: 1 addition & 2 deletions ios/Approach/Sources/GamesEditorFeature/GamesEditor.swift
Original file line number Diff line number Diff line change
Expand Up @@ -327,8 +327,7 @@ public struct GamesEditor: Reducer, Sendable {
return .none

case let .didCalculateHighestScorePossible(.success(highestScore)):
state.presentStrikeOutAlert(withFinalScore: highestScore)
return .none
return state.presentStrikeOutAlert(withFinalScore: highestScore)

case let .bowlersResponse(.success(bowlers)):
state.elementsRefreshing.remove(.bowlers)
Expand Down
4 changes: 3 additions & 1 deletion ios/Approach/Sources/ScoreKeeperLibrary/ScoreKeeper.swift
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,9 @@ public class ScoreKeeper {
let standingPinValue = Pin.fullDeck.value - pinsDowned.value
if Frame.isLast(frameIndex) {
let framesNeededForStandingPinValue = standingPinValue > 0 ? 1 : 0
return Pin.fullDeck.value * (Frame.NUMBER_OF_ROLLS - frame.count - framesNeededForStandingPinValue) + standingPinValue
return Pin.fullDeck.value *
(Frame.NUMBER_OF_ROLLS - frame.count - framesNeededForStandingPinValue) +
standingPinValue
} else {
return standingPinValue + (frame.count == 1 ? 15 : 0)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -642,8 +642,6 @@ final class ScoresRepositoryTests: XCTestCase {
[],
]



framesContinuation.yield(rolls)

let highestScore = try await withDependencies {
Expand Down

0 comments on commit b21504c

Please sign in to comment.