Update src/Content/Widget.php

Co-authored-by: Hypolite Petovan <hypolite@mrpetovan.com>
This commit is contained in:
Philipp 2022-10-21 19:34:02 +02:00 committed by Philipp
parent 44a9683008
commit 7b3caca276
Signed by: nupplaPhil
GPG key ID: 24A7501396EB5432

View file

@ -365,7 +365,7 @@ class Widget
return '';
}
$visitorPCid = DI::userSession()->getLocalUserId() ? Contact::getPublicIdByUserId(DI::userSession()->getLocalUserId()) : DI::userSession()->getRemoteUserId();
$visitorPCid = DI::userSession()->getPublicContactId() ?: DI::userSession()->getRemoteUserId();
if (!$visitorPCid) {
return '';
}