Skip to content

Commit

Permalink
fix: add paranthesis
Browse files Browse the repository at this point in the history
  • Loading branch information
lowlydba authored Feb 23, 2024
1 parent 34ffce2 commit d8c77d7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions public/Set-DbaAgentSchedule.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -344,7 +344,7 @@ function Set-DbaAgentSchedule {
if ($EndDate -and ($EndDate -notmatch $RegexDate)) {
Stop-Function -Message "End date $EndDate needs to be a valid date with format yyyyMMdd" -Target $SqlInstance
return
} elseif ($EndDate -and $EndDate -lt $StartDate) {
} elseif ($EndDate -and ($EndDate -lt $StartDate)) {
Stop-Function -Message "End date $EndDate cannot be before start date $StartDate" -Target $SqlInstance
return
}
Expand Down Expand Up @@ -499,4 +499,4 @@ function Set-DbaAgentSchedule {
if (Test-FunctionInterrupt) { return }
Write-Message -Message "Finished changing the job schedule(s)" -Level Verbose
}
}
}

0 comments on commit d8c77d7

Please sign in to comment.