From 5ebb822f988ed7b38e7f875b70e99d09f8ce410b Mon Sep 17 00:00:00 2001 From: Valeriy Van Date: Sun, 13 Jan 2019 22:58:29 +0100 Subject: [PATCH] Gets rid of magic constant --- Aerial/Source/Models/Time/TimeManagement.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Aerial/Source/Models/Time/TimeManagement.swift b/Aerial/Source/Models/Time/TimeManagement.swift index c09a0e70..21bb31d8 100644 --- a/Aerial/Source/Models/Time/TimeManagement.swift +++ b/Aerial/Source/Models/Time/TimeManagement.swift @@ -393,7 +393,7 @@ final class TimeManagement: NSObject { // MARK: - Battery detection func isOnBattery() -> Bool { - return IOPSGetTimeRemainingEstimate() != -2.0 + return IOPSGetTimeRemainingEstimate() != kIOPSTimeRemainingUnlimited } func isBatteryLow() -> Bool {