mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-02 22:28:37 +02:00
fix cache key
This commit is contained in:
parent
27ccbf77e3
commit
909bee8101
@ -45,6 +45,7 @@ class VersionProvider
|
|||||||
public function getVersion()
|
public function getVersion()
|
||||||
{
|
{
|
||||||
$key = sprintf('%s-%s', $this->getComposerLockPath(), 'all');
|
$key = sprintf('%s-%s', $this->getComposerLockPath(), 'all');
|
||||||
|
$key = preg_replace("/[^A-Za-z0-9]/", '', $key);
|
||||||
$version = $this->getCachedValue($key);
|
$version = $this->getCachedValue($key);
|
||||||
if ($version) {
|
if ($version) {
|
||||||
return $version;
|
return $version;
|
||||||
@ -81,6 +82,7 @@ class VersionProvider
|
|||||||
public function getModuleVersion(string $module): string
|
public function getModuleVersion(string $module): string
|
||||||
{
|
{
|
||||||
$key = sprintf('%s-%s', $this->getComposerLockPath(), $module);
|
$key = sprintf('%s-%s', $this->getComposerLockPath(), $module);
|
||||||
|
$key = preg_replace("/[^A-Za-z0-9]/", '', $key);
|
||||||
$version = $this->getCachedValue($key);
|
$version = $this->getCachedValue($key);
|
||||||
if ($version) {
|
if ($version) {
|
||||||
return $version;
|
return $version;
|
||||||
|
Loading…
Reference in New Issue
Block a user