Skip to content

Commit

Permalink
Merge pull request #164 from jolamar/fix/timestamp-type
Browse files Browse the repository at this point in the history
timestamp should be an int not a double
  • Loading branch information
edamov committed Feb 23, 2023
2 parents 4f5f7d2 + 0cdd8a5 commit 4393f18
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Payload.php
Original file line number Diff line number Diff line change
Expand Up @@ -676,11 +676,11 @@ public function jsonSerialize(): array
$payload[self::PAYLOAD_ROOT_KEY]->{self::PAYLOAD_EVENT_KEY} = $this->event;
}

if (is_double($this->staleDate)) {
if (is_int($this->staleDate)) {
$payload[self::PAYLOAD_ROOT_KEY]->{self::PAYLOAD_STALE_DATE_KEY} = $this->staleDate;
}

if (is_double($this->timestamp)) {
if (is_int($this->timestamp)) {
$payload[self::PAYLOAD_ROOT_KEY]->{self::PAYLOAD_TIMESTAMP_KEY} = $this->timestamp;
}

Expand Down

0 comments on commit 4393f18

Please sign in to comment.