Skip to content

Commit

Permalink
Fix: #4009 - Using old variable name when processing census assistant
Browse files Browse the repository at this point in the history
  • Loading branch information
fisharebest committed Sep 5, 2021
1 parent 23a1643 commit dbecb40
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions app/Http/RequestHandlers/EditFactAction.php
Expand Up @@ -86,10 +86,11 @@ public function handle(ServerRequestInterface $request): ResponseInterface
$census_assistant = $this->module_service->findByInterface(CensusAssistantModule::class)->first();

if ($census_assistant instanceof CensusAssistantModule && $record instanceof Individual) {
$gedcom = $census_assistant->updateCensusAssistant($request, $record, $fact_id, $gedcom, $keep_chan);
$pid_array = $params['pid_array'] ?? '';
if ($pid_array !== '') {
foreach (explode(',', $pid_array) as $pid) {
$ca_individuals = $params['ca_individuals']['xref'] ?? [];

if ($ca_individuals !== []) {
$gedcom = $census_assistant->updateCensusAssistant($request, $record, $fact_id, $gedcom, $keep_chan);
foreach ($ca_individuals as $pid) {
if ($pid !== $xref) {
$individual = Registry::individualFactory()->make($pid, $tree);
if ($individual instanceof Individual && $individual->canEdit()) {
Expand Down

0 comments on commit dbecb40

Please sign in to comment.