Skip to content

Commit

Permalink
Fix static methods
Browse files Browse the repository at this point in the history
  • Loading branch information
tomas-novotny committed Jan 11, 2020
1 parent 47c0c12 commit b00d244
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/Model/Values/TagSet.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,10 @@ protected function tagIds()

foreach ($this->names as $name) {
// get tag hash from static cache or from memcache
$tag = static::$tags[$name] ?? $this->tagId($name);
$tag = self::$tags[$name] ?? $this->tagId($name);

// store tag id to static cache
$ids[] = static::$tags[$name] = $tag;
$ids[] = self::$tags[$name] = $tag;
}

// return tag hashed ids
Expand All @@ -67,7 +67,7 @@ protected function tagIds()
public function resetTag($name)
{
// unset tag value from static cache
unset(static::$tags[$name]);
unset(self::$tags[$name]);

// reset tag value in memcache
return parent::resetTag($name);
Expand All @@ -92,7 +92,7 @@ public function tagKey($name)
*/
public static function resetCachedTags(): void
{
static::$tags = [];
self::$tags = [];
}

/**
Expand All @@ -102,6 +102,6 @@ public static function resetCachedTags(): void
*/
public static function getCachedTags(): array
{
return static::$tags;
return self::$tags;
}
}

0 comments on commit b00d244

Please sign in to comment.