Fix goal sorting with archived goals