                 
                 if loggedIn {
                     UserDefaults.standard.set(true, forKey: kDeviceLinkedStatus)
-                    if ((ZypeAppleTVBase.sharedInstance.consumer?.isLoggedIn) == true){
+                    if (ZypeAppleTVBase.sharedInstance.consumer?.isLoggedIn) == true {
                         print("YaY")
                     }
                     else {

    
    open static func livestreamStopped() {
        let playedForDuration = Int(Date().timeIntervalSince1970 - ZypeAppSettings.sharedInstance.limitLivestream.starts)
         ZypeAppSettings.sharedInstance.limitLivestream.played = ZypeAppSettings.sharedInstance.limitLivestream.played + playedForDuration
        print("stopped playing: \(ZypeAppSettings.sharedInstance.limitLivestream.played)")
    }
    
    open static func livestreamLimitReached() -> Bool {
       //if limit livestream not set return false
        if (!ZypeAppSettings.sharedInstance.limitLivestream.isSet){
            return false
        }

                    ZypeAppSettings.sharedInstance.limitLivestream.isSet = true
                }
                catch _ {
                    ZypeLog.error("Exception: ZobjectModel - Limit")
                }
                ZypeAppSettings.sharedInstance.limitLivestream.refreshRate = Int((limitLivestream?.getStringValue("refresh_rate"))!)!
                
                ZypeAppSettings.sharedInstance.limitLivestream.message =  (limitLivestream?.getStringValue("message"))!
            }
