Commit 36e0bcab authored by Benjamin Winger's avatar Benjamin Winger replaced dataclass with total_ordering to remove python3.7-only code

parent fdaf5a9c
......@@ -2,7 +2,7 @@
# Distributed under the terms of the GNU General Public License v3
from typing import Any
from dataclasses import dataclass, field
from functools import total_ordering
import os
import sys
import argparse
......@@ -22,10 +22,17 @@ from .main import configure_mods
from .config import read_config, remove_config, write_config
class PrioritizedItem:
priority: int
item: Any = field(compare=False)
item: Any
def __init__(self, priority, item):
self.priority = priority
self.item = item
def __lt__(self, other):
return self.priority < other.priority
def migrate():
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment