Skip to content

Commit

Permalink
Merge pull request #700 from valeriyvan/magic
Browse files Browse the repository at this point in the history
Gets rid of magic constant
  • Loading branch information
glouel authored Jan 24, 2019
2 parents 150d004 + 5ebb822 commit 30911aa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Aerial/Source/Models/Time/TimeManagement.swift
Original file line number Diff line number Diff line change
Expand Up @@ -393,7 +393,7 @@ final class TimeManagement: NSObject {

// MARK: - Battery detection
func isOnBattery() -> Bool {
return IOPSGetTimeRemainingEstimate() != -2.0
return IOPSGetTimeRemainingEstimate() != kIOPSTimeRemainingUnlimited
}

func isBatteryLow() -> Bool {
Expand Down

0 comments on commit 30911aa

Please sign in to comment.