Skip to content

Commit

Permalink
add checker category PATCHER (#852)
Browse files Browse the repository at this point in the history
Co-authored-by: noO0ob <[email protected]>
  • Loading branch information
noO0oOo0ob and noO0ob authored May 20, 2024
1 parent 63cdfe5 commit a70e212
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lyrebird/checker/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@
class ExtensionCategory:
MODIFIER = "Modifier"
CHECKER = "Checker"
PATCHER = "Patcher"
OTHER = "Other"

# TODO: For old version compatibility, need to delete
Expand All @@ -53,7 +54,7 @@ class ExtensionCategory:

@classmethod
def get_order(cls, category):
orders = [cls.MODIFIER, cls.EDITOR, cls.CHECKER, cls.OTHER, cls.DEFAULT]
orders = [cls.MODIFIER, cls.EDITOR, cls.CHECKER, cls.OTHER, cls.DEFAULT, cls.PATCHER]
if category not in orders:
return len(orders) + 1
return orders.index(category)
Expand All @@ -63,6 +64,7 @@ def get_description(cls, category):
descriptions = {
cls.MODIFIER: 'Modify flow',
cls.CHECKER: 'Check event and make notification',
cls.PATCHER: 'Dynamically add supplementary logic to Lyrebird',
cls.DEFAULT: 'Testability support, Advanced usage, etc.',

# TODO: For old version compatibility, need to delete
Expand Down

0 comments on commit a70e212

Please sign in to comment.