Skip to content

Commit 61cf739

Browse files
authored
Fixed api pathing issue in OpCon_GetDailyJobs
1 parent de10cf3 commit 61cf739

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

Module/OpConModule.psm1

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -994,12 +994,13 @@ function OpCon_GetDailyJob($url,$token,$sname,$jname,$date,$id)
994994

995995
if($date -and ($jname -or $sname))
996996
{ $uriget = $uriget + "&dates=" + $date }
997-
else
998-
{ $uriget = $url + "/api/dailyjobs?ScheduleDates=" + $date }
997+
elseif($date)
998+
{ $uriget = $url + "/api/dailyjobs?dates=" + $date }
999999
}
10001000

10011001
try
10021002
{
1003+
10031004
$jobs = Invoke-RestMethod -Method GET -Uri $uriget -Headers @{"authorization" = $token} -ContentType "application/json"
10041005

10051006
if($jname)

0 commit comments

Comments
 (0)