MCPcopy Create free account
hub / github.com/acl-dev/acl / check_status

Method check_status

lib_acl_cpp/src/redis/redis_command.cpp:533–549  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

531}
532
533bool redis_command::check_status(const char* success /* = "OK" */)
534{
535 const redis_result* result = run();
536 if (result == NULL || result->get_type() != REDIS_RESULT_STATUS) {
537 logger_result(result);
538 return false;
539 }
540
541 const char* status = result->get_status();
542 if (status == NULL || *status == '\0') {
543 return false;
544 } else if (success == NULL || strcasecmp(status, success) == 0) {
545 return true;
546 } else {
547 return false;
548 }
549}
550
551int redis_command::get_status(std::vector<bool>& out)
552{

Callers

nothing calls this directly

Calls 3

runFunction · 0.50
get_typeMethod · 0.45
get_statusMethod · 0.45

Tested by

no test coverage detected