Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Doctrine] doctrine casts bigint to string, so we have to cast it to int #1062

Merged
merged 1 commit into from
Aug 9, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/CoreShop/Component/Core/Model/ProductStoreValues.php
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ public function setId(int $id)
*/
public function getPrice()
{
return $this->price;
return (int)$this->price;
}

/**
Expand Down
6 changes: 3 additions & 3 deletions src/CoreShop/Component/Core/Model/QuantityRange.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class QuantityRange extends BaseQuantityRange implements QuantityRangeInterface
*/
public function getAmount()
{
return $this->amount;
return (int)$this->amount;
}

/**
Expand Down Expand Up @@ -98,15 +98,15 @@ public function hasUnitDefinition()
*/
public function getPseudoPrice()
{
return $this->pseudoPrice;
return (int)$this->pseudoPrice;
}

/**
* {@inheritdoc}
*/
public function hasPseudoPrice()
{
return $this->pseudoPrice !== 0;
return $this->getPseudoPrice() !== 0;
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public function setId(int $id)
*/
public function getPrice()
{
return $this->price;
return (int)$this->price;
}

/**
Expand Down