Added support for arrays in results