    
    // MARK: text input fields
    
-   func numberOfFields(question: [String : Any]) -> Int {
+   func numberOfFields(question: [String : Any?]) -> Int {
       let fields = question["fields"] as! [[String : String]]
       return fields.count
    }

      return isCompleteAnswer(answer, question : question)
   }
   
   func isCompleteAnswer(_ answer: Any?, question: [String : Any]) -> Bool {
      let questionId = self.id(for: question)
      let questionType = self.questionType(for: question)
      if let stringAnswer = answer as? String {

      return question["options"] as! [String]?
   }
   
   func numberOfTableQuestions(for question: [String : Any?]) -> Int {
      return tableQuestions(for: question).count
   }
   
   func tableQuestions(for question: [String : Any?]) -> [[String : String]] {
      return question["table_questions"] as! [[String : String]]
   }
   
