<?php /** * @return array the cached instance of this widget if it's not empty */ private function getCachedWidget() { $cache = wp_cache_get($this->getWidgetSlug(), 'widget'); if (!empty($cache)) { return $cache; } return []; }