memgraph/query_modules/convert.py

11 lines
151 B
Python
Raw Normal View History

from json import loads
import mgp
@mgp.function
def str2object(string: str) -> mgp.Any:
if string:
return loads(string)
return None