Enum case switch not found in type

Can someone please help me with this.

I have the following public enum

  • How to show a Info window in iOS Google maps without tapping on Marker?
  • How to get a reference to button from UITableViewRowAction?
  • AFNetworking multiple files upload
  • POST multiple json objects in Alamofire POST method - Swift/IOS
  • dyld: dyld_sim not compatible mach-o
  • didRegisterForRemoteNotificationsWithDeviceToken is not called up in ios 9
  • public enum OfferViewRow {
        case Candidates
        case Expiration
        case Description
        case Timing
        case Money
        case Payment

    And the following mutableProperty:

    private let rows = MutableProperty<[OfferViewRow]>([OfferViewRow]())

    In my init file I use some reactiveCocoa to set my MutableProperty:

    rows <~ application.producer
        .map { response in
            if response?.application.status == .Applied {
                return [.Candidates, .Description, .Timing, .Money, .Payment]
            } else {
                return [.Candidates, .Expiration, .Description, .Timing, .Money, .Payment]

    But now the problem, when I try to get the value of my enum inside my rows it throws errors. Please look at the code below.

     func cellViewModelForRowAtIndexPath(indexPath: NSIndexPath) -> ViewModel {
                let row = rows.value[indexPath.row],
                let response = self.application.value
                else {
            switch row {
            case .Candidates:
                 // Do something
            case .Expiration:
                // Do something
            case .Description:
               // Do something
            case .Timing:
               // Do something
            case .Money:
               // Do something
            case .Payment:
               // Do something

    It throws an error: Enum case 'some' not found in type 'OfferViewRow on the line let row = rows.value[indexPath.row]

    And on every switch statements it throws: Enum case 'Candidates' not found in type '<<Error type>>

    Can someone help me with this?

    Solutions Collect From Internet About “Enum case switch not found in type”

    The guard statement wants an optional, as hinted by “Enum case ‘some'” in the error message.

    But rows.value[indexPath.row] is not Optional<OfferViewRow>, it is a raw OfferViewRow. So it won’t enter a guard statement.

    Move let row = rows.value[indexPath.row] one line up: Swift takes care of bounds checking, and will crash if indexPath.row is out of bounds.