                             let atimeTillOpen = (Int)(activeEvent.startDate.timeIntervalSinceNow/Double(60))
                             if let bActiveEvent = b.activeEventForDate(date){
                                 let bTimeTillOpen = (Int)(bActiveEvent.startDate.timeIntervalSinceNow/Double(60))
-                                if atimeTillOpen < bTimeTillOpen {
-                                    return true
-                                } else {
-                                    return false
-                                }
+                                return atimeTillOpen < bTimeTillOpen
                             } else {
                                 return true
                             }
                         }
                     }
                 }
-            }
             
-            else if sortingType == .Alphabetically {
+            case .Alphabetically:
                 let aState = a.generateDescriptionOfCurrentState()
                 let bState = b.generateDescriptionOfCurrentState()
                 

        let meals: [String] = Array((events ?? [:]).keys)
        var selectedMeal = meal
        
        switch(selectedMeal) {
        case "Breakfast":
            if meals.contains("Breakfast") {
                selectedMeal = "Breakfast"

    
    func sortMenu(menu: [(String, [MenuItem])] ) -> [(String, [MenuItem])] {
        return menu.sort {
            if $0.0 == "Hot Traditional Station - Entrees" {
                return true
            }
            return $0.0 == "Hot Traditional Station - Sides" && $1.0 != "Hot Traditional Station - Entrees"
        }
    }
    
    func sortEateriesByOpenOrAlph(eatery: [Eatery], date: NSDate = NSDate(), selectedMeal: String = "None", sortingType: SortType = .Time) -> [Eatery] {
        let sortByHoursClosure = { (a: Eatery, b: Eatery) -> Bool in
            switch sortingType {
            case .LookAhead:
                let eventsA = a.eventsOnDate(date)
                let eventsB = b.eventsOnDate(date)
                if eventsA[self.getSelectedMeal(a, date: date, meal: selectedMeal)] != nil {
                    if eventsB[self.getSelectedMeal(b, date: date, meal: selectedMeal)] != nil {
                        return  a.nickname.lowercaseString < b.nickname.lowercaseString
                    }
                    return true
                }
                return  a.nickname.lowercaseString < b.nickname.lowercaseString
                
            case .Time:
                if a.isOpenToday() {
                    if let activeEvent = a.activeEventForDate(date) {
                        if activeEvent.occurringOnDate(date) {
                            if let bTimeInterval = b.activeEventForDate(date) {
                                return activeEvent.endDate.timeIntervalSinceNow <= bTimeInterval.endDate.timeIntervalSinceNow
                            } else {
                                return true
                            }
