ezsystems/ezpublish-legacy — pull request #1057 by peterkeung (2014-08-11 17:45:18+00:00)
Title: Fix for EZP-23249: Clear prioritized language list cache when switching siteaccesses

Note: this replaces https://github.com/ezsystems/ezpublish-legacy/pull/1054

If you need to loop through several siteaccess to access content, the prioritized language list is not updated.
For example, this code will always return the "UK" name for every siteaccess:

```
$siteAccesses = array( 'uk', 'us', 'de' );
foreach( $siteAccesses as $siteAccessName )
{
$cli->output( $siteAccessName );

$access = array( 'name' => $siteAccessName, 'type' => eZSiteAccess::TYPE_STATIC );
eZSiteAccess::load( $access );

$node = eZFunctionHandler::execute( 'content', 'node', array( 'node_id' => 60 ) );
$cli->output( $node->attribute( 'object' )->attribute( 'name' ) );
}
```