ParticipantService - getParticipant() method - get all participants of survey first (to avoid problem when participants exist but are not loaded)

This commit is contained in:
Meritoo
2017-09-29 14:20:31 +02:00
parent dfa64fee43
commit cacb2b3b92
2 changed files with 6 additions and 1 deletions

View File

@@ -160,6 +160,11 @@ class ParticipantService
*/
public function getParticipant($surveyId, $email)
{
/*
* I have to get all participants of survey to avoid problem when participants exist but are not loaded
*/
$this->getSurveyParticipants($surveyId);
return $this
->allParticipants
->getParticipantOfSurvey($surveyId, $email);

View File

@@ -125,7 +125,7 @@ class ParticipantServiceTest extends BaseTestCase
public function testGetParticipant()
{
$rpcClientManager = $this->getJsonRpcClientManager(0);
$rpcClientManager = $this->getJsonRpcClientManager(1);
$sessionManager = $this->getSessionManager();
$this->createServiceWithoutParticipants($rpcClientManager, $sessionManager);