Bug Fixes For Bar Sorting