Created
October 10, 2014 11:57
-
-
Save mbn18/7ea2f627de4b2220dc18 to your computer and use it in GitHub Desktop.
unset does not effect the object which is outside the method context
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Delete an entity from the global identity map and all other queues | |
* @param AbstractDomainEntity $entity | |
*/ | |
static public function unRegister(AbstractDomainEntity $entity) | |
{ | |
$instance = self::getInstance(); | |
$instance->registerClean($entity); | |
unset($instance->all[$instance->globalKey($entity)]); | |
unset($entity); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment