Fixed bug where data set not being sorted on consecutive calls.