From 7ba3b08b7d26884259cdc378b1d9d8a8d0ce977a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Samuel=20=C5=A0tancl?= Date: Thu, 25 Jun 2020 10:42:27 +0200 Subject: [PATCH] Fix impersonation tokens --- source/docs/v3/features/user-impersonation.blade.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/docs/v3/features/user-impersonation.blade.md b/source/docs/v3/features/user-impersonation.blade.md index 072d7d9..76f8850 100644 --- a/source/docs/v3/features/user-impersonation.blade.md +++ b/source/docs/v3/features/user-impersonation.blade.md @@ -86,14 +86,14 @@ And redirect the user (or, presumably an "admin") to the route you created. // a concept of "primary domains" if you need them. Or maybe you use // one domain per tenant. The package lets you do anything you want. $domain = $tenant->primary_domain; -return redirect("https://$domain/impersonate/$token"); +return redirect("https://$domain/impersonate/{$token->token}"); ``` ### Path identification ```jsx // Make sure you use the correct prefix for your routes. -return redirect("{$tenant->id}/impersonate/$token"); +return redirect("{$tenant->id}/impersonate/{$token->token}"); ``` And that's it. The user will be redirected to your impersonation route, logged in as the impersonated user, and finally redirected to your redirect URL.