Skip to content

Commit

Permalink
Fix typo in consent cache Key
Browse files Browse the repository at this point in the history
  • Loading branch information
cannycookie committed Dec 16, 2024
1 parent 98fef72 commit 47d7ef1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Traits/HasConsent.php
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ public function activeConsents()
public function hasRequiredConsents()
{
// Define a unique cache key based on identifiable attributes including the model class
$cacheKey = 'user_consent_'.class_basename($this).'-'.$this->getKey();
$cacheKey = 'user_consent_'.class_basename($this).'_'.$this->getKey();

// Retrieve from cache or calculate if not cached
return Cache::tags(['user-consents'])->rememberForever($cacheKey, function () {
Expand Down

0 comments on commit 47d7ef1

Please sign in to comment.