private static OptionDescription extractOption(Object item) {
    if (item == null) return null;

    if (item instanceof GotoActionModel.MatchedValue) {
      item = ((GotoActionModel.MatchedValue)item).value;
    }

    return item instanceof OptionDescription ? (OptionDescription)item : null;
  }
private static OptionDescription extractOption(Object item)