Skip to content

Commit 32a2195

Browse files
authored
Merge pull request #12 from abspr/master
formatter crash fix on apple silicon
2 parents 720dee1 + c47b935 commit 32a2195

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

MagicTimer/Classes/MGStandardTimerFormatter.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,9 @@ class MGStandardTimerFormatter: DateComponentsFormatter, MGTimeFormatter {
3434
func converToValidFormat(ti: TimeInterval) -> String? {
3535
switch ti {
3636
case let x where Int(x) >= MGTimeUnit.hour.rawValue:
37-
allowedUnits = [.minute, .second, .hour]
37+
allowedUnits = [.hour, .minute, .second]
3838
case let x where Int(x) <= MGTimeUnit.hour.rawValue:
39-
allowedUnits = [.minute, .second, .nanosecond]
39+
allowedUnits = [.minute, .second]
4040
default:
4141
break
4242
}

0 commit comments

Comments
 (0)