Debian Codegraph @

valkey/commands/search/_util.py

raw
1 def to_string(s):
2 if isinstance(s, str):
3 return s
4 elif isinstance(s, bytes):
5 return s.decode("utf-8", "ignore")
6 else:
7 return s # Not a string we care about