title: R leaflet search doesn't zoom to correct place after clicking search result
body: <p>I've set up a map of local voting precincts and want to be able to search precinct number. The goal is that the user can type a precinct number into the search box, click the correct precinct, and the map would zoom to that precinct.</p>
  <p>Instead, when a user searches a precinct number, Leaflet returns the full contents of the precinct's mouseover label information, and when the user clicks that result, the map shows an error saying &quot;Location not found.&quot;</p>
  <p>Code below, Github repo with <a href="https://github.com/chrismp/r-leaflet-search-problem" rel="nofollow noreferrer">original shapefile and CSV data file here</a>.</p>
  <pre><code>library(rgdal)
  library(leaflet)
  library(leaflet.extras)
  library(htmltools)
  library(tigris)
  library(htmlwidgets)
  library(dplyr)
  
  m16 &lt;- geo_join(
    spatial_data = readOGR(
      dsn = &quot;Precinct_2016/PRECINCT_REDISTRICTING_region.shp&quot;,
      layer = &quot;PRECINCT_REDISTRICTING_region&quot;
    ),
    data_frame = read.csv(&quot;2016 results by precinct.csv&quot;),
    by_sp = &quot;PRECINCT&quot;,
    by_df = &quot;Precinct&quot;,
    how = &quot;inner&quot;
  )
  
  label16 &lt;- sprintf(
    fmt = &quot;&lt;strong&gt;Precinct %s&lt;/strong&gt;&lt;br&gt;
          Hillary Clinton: %g (%g%%) &lt;br&gt;
          Donald Trump: %g (%g%%) &lt;br&gt;&quot;,
    m16$Precinct, m16$Hillary.Rodham.Clinton, m16$Percent.Clinton, m16$Donald.J..Trump, m16$Percent.Trump
  ) %&gt;% lapply(htmltools::HTML)
  
  leaflet() %&gt;%
    addProviderTiles(providers$CartoDB.Positron) %&gt;%
    addPolygons(
      data = m16,
      group = &quot;2016&quot;,
      label = label16
    ) %&gt;%
    addSearchFeatures(
      targetGroups = &quot;2016&quot;,
      options = searchFeaturesOptions(
        textPlaceholder = &quot;Search precinct&quot;
      )
    )
  </code></pre>