Skip to content

Commit

Permalink
Fix : Wrong type for '+' and '-' operators
Browse files Browse the repository at this point in the history
  • Loading branch information
s-renier-taonix-fr authored and f3l1x committed Feb 13, 2023
1 parent cee976b commit c482f61
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/nusoap.php
Original file line number Diff line number Diff line change
Expand Up @@ -992,11 +992,11 @@ function iso8601_to_timestamp($datestr)
$h = substr($regs[8], 1, 2);
$m = substr($regs[8], strlen($regs[8]) - 2, 2);
if ($op == '-') {
$regs[4] = $regs[4] + $h;
$regs[5] = $regs[5] + $m;
$regs[4] = intval ($regs[4]) + intval ($h);
$regs[5] = intval ($regs[5]) + intval ($m);
} elseif ($op == '+') {
$regs[4] = $regs[4] - $h;
$regs[5] = $regs[5] - $m;
$regs[4] = intval ($regs[4]) - intval ($h);
$regs[5] = intval ($regs[5]) - intval ($m);
}
}
return gmmktime($regs[4], $regs[5], $regs[6], $regs[2], $regs[3], $regs[1]);
Expand Down

0 comments on commit c482f61

Please sign in to comment.