/** * Main SSP_Stats Instance * * Ensures only one instance of SSP_Stats is loaded or can be loaded. * * @since 1.0.0 * @static * @see SSP_Stats() * @return Main SSP_Stats instance */ public static function instance($file = '', $version = '1.0.0', $db_version = '1.0.0') { if (is_null(self::$_instance)) { self::$_instance = new self($file, $version, $db_version); } return self::$_instance; }
/** * Returns the main instance of SSP_Stats to prevent the need to use globals. * * @since 1.0.0 * @return object SSP_Stats */ function SSP_Stats() { $instance = SSP_Stats::instance(__FILE__, '1.1', '1.0.0'); return $instance; }