Skip to content
Permalink
Browse files

Merge ea72be7 into 1afff8c

  • Loading branch information...
chadicus committed Jan 7, 2016
2 parents 1afff8c + ea72be7 commit bf55cf533a2f509a30192b882a594650e0aa7560
Showing with 11 additions and 0 deletions.
  1. +11 −0 src/ImmutableKeyValuePair.php
@@ -51,4 +51,15 @@ public function getValue()
{
return $this->value;
}
/**
* Ensures deep copy when cloning.
*
* @return void
*/
public function __clone()
{
$this->key = is_object($this->key) ? clone $this->key : $this->key;
$this->value = is_object($this->value) ? clone $this->value : $this->value;
}
}

0 comments on commit bf55cf5

Please sign in to comment.
You can’t perform that action at this time.