Skip to content

Commit 9443742

Browse files
committed
Reorder usage example
1 parent 0b1007c commit 9443742

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

README.md

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,12 +37,11 @@ class UserController extends Controller
3737
*/
3838
public function store(Request $request)
3939
{
40-
$user = new \App\User();
41-
$user->name = $request->name;
42-
43-
// $request->country() will perform geolocation, and return a detailed country object.
40+
// Perform geolocation, and return a country object.
4441
$country = $request->country();
4542

43+
$user = new \App\User();
44+
$user->name = $request->name;
4645
$user->countryName = $country->name;
4746
$user->countryCode = $country->isoCodeAlpha3;
4847

0 commit comments

Comments
 (0)