Explorar el Código

Fix bug where loop doesn't break after first attempt is successful

Alan Lam hace 7 años
padre
commit
c8ed091db0
Se han modificado 1 ficheros con 1 adiciones y 0 borrados
  1. 1 0
      tasks/import_venues.php

+ 1 - 0
tasks/import_venues.php

@@ -152,6 +152,7 @@ for($i = 0; $data = fgetcsv($handle); $i++) {
 					$result = $results[0];
 					$location->latitude = $result->geometry->location->lat;
 					$location->longitude = $result->geometry->location->lng;
+					break;
 				}
 			}
 			catch(Exception $e) {