MCPcopy Create free account
hub / github.com/F-Stack/f-stack / value_or_delete

Function value_or_delete

app/redis-6.2.6/tests/modules/hash.c:8–13  ·  view source on GitHub ↗

If a string is ":deleted:", the special value for deleted hash fields is * returned; otherwise the input string is returned. */

Source from the content-addressed store, hash-verified

6/* If a string is ":deleted:", the special value for deleted hash fields is
7 * returned; otherwise the input string is returned. */
8static RedisModuleString *value_or_delete(RedisModuleString *s) {
9 if (!strcasecmp(RedisModule_StringPtrLen(s, NULL), ":delete:"))
10 return REDISMODULE_HASH_DELETE;
11 else
12 return s;
13}
14
15/* HASH.SET key flags field1 value1 [field2 value2 ..]
16 *

Callers 1

hash_setFunction · 0.85

Calls 1

strcasecmpFunction · 0.85

Tested by

no test coverage detected