Skip to content

Commit

Permalink
Gets rid of magic constant
Browse files Browse the repository at this point in the history
  • Loading branch information
valeriyvan committed Jan 13, 2019
1 parent 810bfab commit 5ebb822
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 5ebb822

Please sign in to comment.