Skip to content

Commit

Permalink
Set (bool) before function
Browse files Browse the repository at this point in the history
  • Loading branch information
Reindert authored Sep 4, 2017
1 parent a3fe637 commit c785afb
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions app/code/Magento/Sales/Model/Order.php
Original file line number Diff line number Diff line change
Expand Up @@ -1774,17 +1774,17 @@ public function getTracksCollection()
*/
public function hasInvoices()
{
return $this->getInvoiceCollection()->count();
return (bool)$this->getInvoiceCollection()->count();
}

/**
* Check order shipments availability
*
* @return int
* @return bool
*/
public function hasShipments()
{
return $this->getShipmentsCollection()->count();
return (bool)$this->getShipmentsCollection()->count();
}

/**
Expand All @@ -1794,7 +1794,7 @@ public function hasShipments()
*/
public function hasCreditmemos()
{
return $this->getCreditmemosCollection()->count();
return (bool)$this->getCreditmemosCollection()->count();
}

/**
Expand Down

0 comments on commit c785afb

Please sign in to comment.