private function validateFieldModel(FieldModel $field)
{
if (!$field->getFieldType()) {
$fieldType = $field->type;
$fieldType == 'Matrix' ? $this->addError("One of the field's types does not exist. Are you missing a plugin?") : $this->addError("Field type '{$fieldType}' does not exist. Are you missing a plugin?");
throw new Exception('Failed to save field');
}
}