Fix bsort to include sort_attrs.