Fixed bug I'm surprised is in here for so long - error object was circular reference