(self)
Return if switch is on.
Return if switch is on.
Return if switch is on .
def is_on(self):
        """Return if switch is on."""
        if self.coordinator.data:
            if self.coordinator.data["appVersionCode"] < 784:
                return self.coordinator.data["currentFragment"] == "screensaver"
            return self.coordinator.data["isInScreensaver"]
def is_on ( self ) : if self . coordinator . data : if self . coordinator . data [ "appVersionCode" ] < 784 : return self . coordinator . data [ "currentFragment" ] == "screensaver" return self . coordinator . data [ "isInScreensaver" ]