                     let hiddenID = (dict.value(forKey: "hiddenID") as? Int)!
                     let profilename = dict.value(forKey: "profilename") ?? NSLocalizedString("Default profile", comment: "default profile")
                     let time = seconds
-                    let dict: NSDictionary = [
+                    let dictschedule: NSDictionary = [
                         "start": dateStart,
                         "hiddenID": hiddenID,
                         "dateStart": dateStart,

                        "timetostart": time,
                        "profilename": profilename,
                    ]
                    self.expandedData?.append(dict)
                case Scheduletype.daily.rawValue:
                    self.daily(dateStart: dateStart, schedule: schedule, dict: dict)
                case Scheduletype.weekly.rawValue:

    private func sortAndExpandScheduleTasks() {
        for i in 0 ..< (self.schedulesNSDictionary?.count ?? 0) {
            let dict = self.schedulesNSDictionary![i]
            let dateStop: Date = (dict.value(forKey: "dateStop") as? String)?.en_us_date_from_string() ?? Date()
            let dateStart: Date = (dict.value(forKey: "dateStart") as? String)?.en_us_date_from_string() ?? Date()
            let schedule: String = (dict.value(forKey: "schedule") as? String) ?? Scheduletype.once.rawValue
            let seconds: Double = dateStop.timeIntervalSinceNow
            // Get all jobs which are not executed
            if seconds > 0 {
