diff --git a/app/code/Magento/Sales/Model/Order/Config.php b/app/code/Magento/Sales/Model/Order/Config.php index 92d631d1f78c0..e9d8f7908ff23 100644 --- a/app/code/Magento/Sales/Model/Order/Config.php +++ b/app/code/Magento/Sales/Model/Order/Config.php @@ -49,6 +49,11 @@ class Config */ protected $state; + /** + * @var array + */ + private static $orderStatusOptionHashCache; + /** * @var array */ @@ -195,8 +200,10 @@ public function getStateLabel($state) */ public function getStatuses() { - $statuses = $this->orderStatusCollectionFactory->create()->toOptionHash(); - return $statuses; + if (!isset(static::$orderStatusOptionHashCache)) { + static::$orderStatusOptionHashCache = $this->orderStatusCollectionFactory->create()->toOptionHash(); + } + return static::$orderStatusOptionHashCache; } /**