I'm using this code to show subcategories on the category page. I was working fine in 1.9.2.0 but is broken in 1.9.2.2. Does anyone have the updated code?
<?php
$category = Mage::getSingleton('catalog/layer')->getCurrentCategory();
$categories = $category->getCollection()
->addAttributeToSelect(array('name', 'image'))
->addAttributeToFilter('is_active', 1)
->addIdFilter($category->getChildren())
?>
<h2>Choose A Subcategory...</h2>
<ul class="subcategories">
<?php foreach ($categories as $category): ?>
<li>
<a href="<?php echo $category->getUrl() ?>"><img src="<?php echo $category->getImageUrl() ?>" alt="<?php echo $this->htmlEscape($category->getName()) ?>" /><br />
<span><?php echo $category->getName() ?></span></a>
</li>
<?php endforeach; ?>
</ul>
<span class="clear"></span>