Fixes incorrect prefix placement for sort array