PHP 8.2.31
Preview: parsing.js Size: 206 B
/home/nshryvcy/radiantskinclinics.org/wp-content/plugins/extendify_old/src/Shared/lib/parsing.js

export const safeParseJson = (json, fallback = {}) => {
	if (typeof json !== 'string') {
		return json ?? fallback;
	}
	try {
		return JSON.parse(json) ?? fallback;
	} catch (_e) {
		return fallback;
	}
};

Directory Contents

Dirs: 1 × Files: 8

Name Size Perms Modified Actions
__tests__ DIR
- drwxr-xr-x 2026-04-28 02:40:02
Edit Download
346 B lrw-r--r-- 2025-09-15 23:30:06
Edit Download
341 B lrw-r--r-- 2026-03-05 22:57:38
Edit Download
254 B lrw-r--r-- 2026-02-19 03:27:14
Edit Download
16.27 KB lrw-r--r-- 2026-02-19 03:27:14
Edit Download
206 B lrw-r--r-- 2026-02-19 03:27:14
Edit Download
1.93 KB lrw-r--r-- 2026-02-27 04:48:52
Edit Download
1.72 KB lrw-r--r-- 2026-02-19 03:27:14
Edit Download
499 B lrw-r--r-- 2026-02-19 03:27:14
Edit Download

If ZipArchive is unavailable, a .tar will be created (no compression).