feat: redirect to real contact when it's a partial one (#2353)

This commit is contained in:
Alexis Saettler
2019-01-28 18:50:04 +01:00
committed by GitHub
parent 90f810e8f9
commit f4ffa4d916
9 changed files with 20 additions and 8 deletions
+1 -1
View File
@@ -210,7 +210,7 @@ class ContactsController extends Controller
// make sure we don't display a significant other if it's not set as a
// real contact
if ($contact->is_partial) {
return redirect()->route('people.index');
return redirect()->route('people.show', $contact->getRelatedRealContact());
}
$contact->load(['notes' => function ($query) {
$query->orderBy('updated_at', 'desc');