             let alarms = Alarm(alarmHigh: aHigh, alarmLow: aLow, alarmTimeAgoUrgent: aTAU, alarmTimeAgoUrgentMins: aTAUMin, alarmTimeAgoWarn: aTAW, alarmTimeAgoWarnMins: aTAWMin, alarmUrgentHigh: aTUH, alarmUrgentLow: aTUL)
             
             let language = defaultsDictionary[ConfigurationPropertyKey.languageKey] as! String
-        
+            
             defaultsDefaults = Defaults(units: units, timeFormat: timeFormat, nightMode: nightMode, showRawbg: showRawbg, customTitle: customTitle, theme: theme, alarms: alarms, language: language, showPlugins: nil, enable: nil, thresholds: nil, defaultFeatures: nil)
         }
         

            let bg_target_top = thresholdsDict[ConfigurationPropertyKey.bg_target_topKey] as! Double
            threshold = Threshold(bg_high: bg_high, bg_low: bg_low, bg_target_bottom: bg_target_bottom, bg_target_top: bg_target_top)
        }

        
        var defaultsDefaults: Defaults?
        if let defaultsDictionary = root[ConfigurationPropertyKey.defaultsKey] as? [String: AnyObject] {

            let aHigh = settingsDictionary[ConfigurationPropertyKey.alarmHighKey] as! Bool
            let aLow = settingsDictionary[ConfigurationPropertyKey.alarmLowKey] as! Bool
            let aTAU = settingsDictionary[ConfigurationPropertyKey.alarmTimeagoUrgentKey] as! Bool
            
            // Some sites seem to post a number other seem to have strings.
            var aTAUMDouble: Double = 0
            if let doubleATAUM = settingsDictionary[ConfigurationPropertyKey.alarmTimeagoUrgentMinsKey] as? Double {
                aTAUMDouble = doubleATAUM
            }
            
            if let stringATAUM = settingsDictionary[ConfigurationPropertyKey.alarmTimeagoUrgentMinsKey] as? String {
                aTAUMDouble = Double(stringATAUM)!
            }
            
            let aTAUMin: NSTimeInterval = aTAUMDouble * 60 // Convert minutes to seconds.
            
            let aTAW = settingsDictionary[ConfigurationPropertyKey.alarmTimeagoWarnKey] as! Bool
            
            var aTAWMDouble: Double = 0
            
            if let doubATAW = settingsDictionary[ConfigurationPropertyKey.alarmTimeagoWarnMinsKey] as? Double {
                aTAWMDouble = doubATAW
            }
            
            if let stringATAW = settingsDictionary[ConfigurationPropertyKey.alarmTimeagoWarnMinsKey] as? String {
                aTAWMDouble = Double(stringATAW)!
            }
            
            let aTAWMin: NSTimeInterval = aTAWMDouble * 60 // Convert minutes to seconds.
            let aTUH = settingsDictionary[ConfigurationPropertyKey.alarmUrgentHighKey] as! Bool
            let aTUL = settingsDictionary[ConfigurationPropertyKey.alarmUrgentLowKey] as! Bool
