Skip to content

Commit 8156993

Browse files
committed
to fix the conditions for which a repeatedly schedule should be removed from the scheduler
1 parent 316a589 commit 8156993

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

build.sbt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ ThisBuild / organization := "app.softnetwork"
3131

3232
name := "scheduler"
3333

34-
ThisBuild / version := "0.3.2.1"
34+
ThisBuild / version := "0.3.2.2"
3535

3636
ThisBuild / scalaVersion := "2.12.15"
3737

common/build.sbt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ libraryDependencies ++= Seq(
1111
// session
1212
"app.softnetwork.session" %% "session-core" % Versions.genericPersistence,
1313
"app.softnetwork.api" %% "generic-server-api" % Versions.genericPersistence,
14-
"app.softnetwork.protobuf" %% "scalapb-extensions" % "0.1.6"
14+
"app.softnetwork.protobuf" %% "scalapb-extensions" % "0.1.7"
1515
)
1616

1717
Compile / unmanagedResourceDirectories += baseDirectory.value / "src/main/protobuf"

common/src/main/scala/app/softnetwork/scheduler/model/package.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,8 @@ package object model {
4848
def removable: Boolean = {
4949
// the schedule could not be triggered now
5050
!triggerable &&
51-
// the schedule can not be triggered repeatedly
52-
!repeatedly.getOrElse(false) &&
51+
// the schedule can not be triggered repeatedly or should be triggered at a specified date
52+
(!repeatedly.getOrElse(false) || scheduledDate.isDefined) &&
5353
// the schedule has not defined a date at which it should be triggered
5454
// or it has already been triggered at or after the specified date
5555
(scheduledDate.isEmpty || (lastTriggered.isDefined && (getLastTriggered.after(

0 commit comments

Comments
 (0)