Made json_decode array based appose to object based.