Skip to content

Commit

Permalink
Add a restriction for avoid error 'Numeric value out of range'
Browse files Browse the repository at this point in the history
  • Loading branch information
idmarinas committed Feb 7, 2024
1 parent 56fa454 commit 9855507
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/core/Entity/AccountsEverypage.php
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ public function getAcctid(): int
*/
public function setGentime($gentime)
{
$this->gentime = $gentime;
$this->gentime = min(4_294_967_290, $gentime);

return $this;
}
Expand All @@ -91,7 +91,7 @@ public function setGentime($gentime)
*/
public function getGentime(): float
{
return $this->gentime;
return min(4_294_967_290, $this->gentime);
}

/**
Expand All @@ -103,7 +103,7 @@ public function getGentime(): float
*/
public function setGentimecount($gentimecount)
{
$this->gentimecount = $gentimecount;
$this->gentimecount = min(4_294_967_290, $gentimecount);

return $this;
}
Expand All @@ -113,7 +113,7 @@ public function setGentimecount($gentimecount)
*/
public function getGentimecount(): int
{
return $this->gentimecount;
return min(4_294_967_290, $this->gentimecount);
}

/**
Expand All @@ -125,7 +125,7 @@ public function getGentimecount(): int
*/
public function setGensize($gensize)
{
$this->gensize = $gensize;
$this->gensize = min(4_294_967_290, $gensize);

return $this;
}
Expand All @@ -135,6 +135,6 @@ public function setGensize($gensize)
*/
public function getGensize(): int
{
return $this->gensize;
return min(4_294_967_290, $this->gensize);
}
}

0 comments on commit 9855507

Please sign in to comment.