Change snip content text rebuilding to static, allowing a lot cleaner interface getting the lastest text
This commit is contained in:
@ -15,13 +15,12 @@ class SnipLoader implements LoaderInterface
|
||||
{
|
||||
public function __construct(
|
||||
private readonly SnipRepository $repository,
|
||||
private readonly SnipContentService $contentService,
|
||||
private readonly Security $security,
|
||||
) {}
|
||||
|
||||
public function getSourceContext(string $name): Source
|
||||
{
|
||||
return new Source($this->contentService->getActiveText($this->getFromKey($name)), $name);
|
||||
return new Source($this->getFromKey($name)->getActiveText(), $name);
|
||||
}
|
||||
|
||||
public function getCacheKey(string $name): string
|
||||
|
Reference in New Issue
Block a user