/** * Return a singleton instance of MWCryptRand * @return MWCryptRand */ protected static function singleton() { if (is_null(self::$singleton)) { self::$singleton = new self(); } return self::$singleton; }