     
     // MARK: - Private
     
-    private var lastResult: LocationResult? = nil
-    private var observers: [Observer] = []
-    
     private lazy var locationManager: CLLocationManager = {
         let locationManager = CLLocationManager()
         locationManager.delegate = self


public class LocationTracker: NSObject, CLLocationManagerDelegate {
    
    var currentLocation: LocationResult {
        if let result = lastResult {
            return result
        }
        else {
            return Result.Failure(Reason.NoData)
        }
    }
    
    override init() {

    }
    
    private func shouldUpdateWithLocation(location: CLLocation) -> Bool {
        switch lastResult {
        case .Success(let box):
            return location.distanceFromLocation(box.unbox.physical) > 100
        case .Failure:
            return true
        }
    }
    
    private func shouldUpdateWithResult(result: LocationResult) -> Bool {
        switch lastResult {
        case .Success(let box):
            let location = box.unbox.physical
            return self.shouldUpdateWithLocation(location)
        case .Failure:
            return true
        }
    }
}

