From da208457b86bd03bac94a3990fc21c065ea8d5a2 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Mon, 14 Jun 2021 11:58:06 -0400 Subject: [PATCH] Fix EndTime case handling. --- scripts/ZoneMinder/lib/ZoneMinder/Filter.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/ZoneMinder/lib/ZoneMinder/Filter.pm b/scripts/ZoneMinder/lib/ZoneMinder/Filter.pm index 5711437f2..5c2bf6f43 100644 --- a/scripts/ZoneMinder/lib/ZoneMinder/Filter.pm +++ b/scripts/ZoneMinder/lib/ZoneMinder/Filter.pm @@ -199,10 +199,10 @@ sub Sql { $self->{Sql} .= 'E.EndDateTime'; } elsif ( $term->{attr} eq 'EndDate' ) { $self->{Sql} .= 'to_days( E.EndDateTime )'; - } elsif ( $term->{attr} eq 'EndDateTime' ) { + } elsif ( $term->{attr} eq 'EndTime' ) { $self->{Sql} .= 'extract( hour_second from E.EndDateTime )'; } elsif ( $term->{attr} eq 'EndWeekday' ) { - $self->{Sql} .= "weekday( E.EndDateTime )"; + $self->{Sql} .= 'weekday( E.EndDateTime )'; } elsif ( $term->{attr} eq 'ExistsInFileSystem' ) { push @{$self->{PostSQLConditions}}, $term; $self->{Sql} .= 'TRUE /* ExistsInFileSystem */';