get_ary and set_ary for js