Skip to content

Commit

Permalink
Merge pull request #2794 from dpfaffenbauer/issue/session
Browse files Browse the repository at this point in the history
[StorageList] fix writing null into session
  • Loading branch information
dpfaffenbauer authored Feb 6, 2025
2 parents 7ddffd3 + befc897 commit 63a919d
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,10 @@ public function setForContext(array $context, StorageListInterface $storageList)
throw new \InvalidArgumentException('Session is not available');
}

if (null === $storageList->getId()) {
return;
}

$this->getSession()->set($this->getKeyName($context), $storageList->getId());
}

Expand Down

0 comments on commit 63a919d

Please sign in to comment.