Skip to content

Commit

Permalink
chore: comparison support for scheduler task
Browse files Browse the repository at this point in the history
  • Loading branch information
joamag committed May 4, 2024
1 parent 23dca55 commit 7ef4673
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Fixed

*
* Comparison support for `SchedulerTask`

## [1.33.3] - 2024-05-01

Expand Down
8 changes: 8 additions & 0 deletions src/appier/scheduler.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,14 @@ def __init__(self, job, cron):
self.date = SchedulerDate.from_cron(cron)
self._enabled = True

def __eq__(self, other):
if isinstance(other, self.__class__):
return True
return False

def __lt__(self, other):
return False

def enable(self):
self._enabled = True

Expand Down

0 comments on commit 7ef4673

Please sign in to comment.