mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-17 22:36:01 +00:00
Fix parsing of JSON data
This commit is contained in:
@@ -452,9 +452,10 @@ const driver = {
|
||||
res.value = await dbhan.client.get(key);
|
||||
break;
|
||||
case 'ReJSON-RL':
|
||||
res.type = 'json';
|
||||
res.type = 'JSON';
|
||||
try {
|
||||
res.value = JSON.stringify(await dbhan.client.call('JSON.GET', key), null, 2);
|
||||
const jsonData = await dbhan.client.call('JSON.GET', key);
|
||||
res.value = JSON.stringify(JSON.parse(jsonData), null, 2);
|
||||
} catch (e) {
|
||||
res.value = '';
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user