preserve order of elements in the data call. fixes #1280