diff --git a/codeforces_api/parse_methods.py b/codeforces_api/parse_methods.py index 503a97e..9bdd7b6 100644 --- a/codeforces_api/parse_methods.py +++ b/codeforces_api/parse_methods.py @@ -92,11 +92,6 @@ def get_tags(self, contest_id, index, include_rating=False): index = chr(ord("A") + int(index)) index = index.capitalize() try: - if include_rating: - return self.problem_tags[str(contest_id)][index] - return self.problem_tags[str(contest_id)][index][1:] + return sorted(self.problem_tags[str(contest_id)][index]) except KeyError: - # If problem included in more than one division. - if include_rating: - return self.problem_tags[str(int(contest_id) - 1)][index] - return self.problem_tags[str(int(contest_id) - 1)][index][1:] + return sorted(self.problem_tags[str(int(contest_id) - 1)][index])