fix(common): add defination of COMMON::Utils::instance_

This commit is contained in:
Kieran Kihn
2025-11-16 20:50:42 +08:00
parent 8dbdbb395c
commit f06fee17cc

View File

@@ -12,11 +12,13 @@ namespace UNO::COMMON {
return gen_; return gen_;
} }
Utils* Utils::instance_ = nullptr;
Utils *Utils::getInstance() { Utils *Utils::getInstance() {
if (Utils::instance_ == nullptr) { if (instance_ == nullptr) {
Utils::instance_ = new Utils(); instance_ = new Utils();
} }
return Utils::instance_; return instance_;
} }
Random &Utils::getRandom() { Random &Utils::getRandom() {
return this->random_; return this->random_;