fixed bug where old code treated a dictionary like a list