fixes bug in conversion to javascript array