Replace json_decode function by G::json_decode to support PHP versions without json support configured.