| 503 | } |
| 504 | |
| 505 | const char* FlowHandler::GetString(const char* id) const |
| 506 | { |
| 507 | if (id == nullptr || *id == '\0') |
| 508 | { |
| 509 | TENLog("Provided string ID is empty.", LogLevel::Warning); |
| 510 | return _translationMap.begin()->second[0].c_str(); |
| 511 | } |
| 512 | |
| 513 | if (!ScriptAssert(_translationMap.find(id) != _translationMap.end(), std::string{ "Couldn't find string " } + id)) |
| 514 | { |
| 515 | return id; |
| 516 | } |
| 517 | else |
| 518 | { |
| 519 | return _translationMap.at(std::string(id)).at(0).c_str(); |
| 520 | } |
| 521 | } |
| 522 | |
| 523 | bool FlowHandler::IsStringPresent(const char* id) const |
| 524 | { |
no test coverage detected