Skip to content

Commit

Permalink
Merge pull request #74 from creative-commoners/pulls/1/stop-depr
Browse files Browse the repository at this point in the history
API Stop using deprecated API
  • Loading branch information
sabina-talipova authored Nov 13, 2022
2 parents 453f6d6 + f49fcd5 commit ec39cb4
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/Collections/MemoryConfigCollection.php
Original file line number Diff line number Diff line change
Expand Up @@ -221,8 +221,16 @@ public function update($class, $name, $value)
return $this;
}

/**
* @param string $class
* @param string $name
* @param array $value - non-array values are @deprecated 1.12.0
*/
public function merge($class, $name, $value)
{
if (!is_array($value)) {
Deprecation::notice('1.12.0', 'Use set() if $value is not an array instead');
}
// Detect mergeable config
$existing = $this->get($class, $name, true);
if (is_array($value) && is_array($existing)) {
Expand Down

0 comments on commit ec39cb4

Please sign in to comment.