Skip to content

Commit

Permalink
Merge pull request #2 from atehrani/patch-1
Browse files Browse the repository at this point in the history
Fix for dcoffing#6
  • Loading branch information
CovertJaguar authored Aug 13, 2020
2 parents b145a97 + 023ca77 commit 76a44fa
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -273,8 +273,8 @@ private tempCheck(currentTemp, desiredTemp)
private hasBeenRecentMotion()
{
def isActive = false
if (motionSensor && minutes) {
def deltaMinutes = minutes as Long
if (motionSensor && minutesNoMotion) {
def deltaMinutes = minutesNoMotion as Long
if (deltaMinutes) {
def motionEvents = motionSensor.eventsSince(new Date(now() - (60000 * deltaMinutes)))
log.trace "Found ${motionEvents?.size() ?: 0} events in the last $deltaMinutes minutes"
Expand Down Expand Up @@ -309,4 +309,4 @@ private def textHelp() {
" in the Hampton Bay Wink Ceiling Fan MR101Z receiver in the Gardinier 52' Ceiling Fan or"+
" Universal Ceiling Fan Premier Remote from Home Depot."

}
}

0 comments on commit 76a44fa

Please sign in to comment.