Skip to content

Commit

Permalink
rename badly named function
Browse files Browse the repository at this point in the history
  • Loading branch information
PabloJoan committed Nov 29, 2023
1 parent 43f74fd commit 1ba43eb
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/Configurations/Config.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,11 @@ public function __construct(array $config)
}

/**
* Using a random 0 - 100 number or a 0 - 100 number hashed from an id,
* Using a random 0 - 99 number or a 0 - 99 number hashed from an id,
* Select the variant where this random or hashed integer falls within it's
* calculated integer range.
*/
public function pickVariantOutOfHat(string $id): string
public function getEnabledVariant(string $id): string
{
$hashOrRandomNumber = $this->bucketing->strToIntHash($id);

Expand Down
2 changes: 1 addition & 1 deletion src/Features.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,6 @@ public function getEnabledVariant(
string $id = ''
): string
{
return $this->features->get($featureName)->pickVariantOutOfHat($id);
return $this->features->get($featureName)->getEnabledVariant($id);
}
}

0 comments on commit 1ba43eb

Please sign in to comment.