Bar Sorting Bug Fix