Fixed bug in attribute cache.