Previously I was using google place Api to fetch and display reviews but now they do not fetch new reviews dont know why. I am getting this ERROR deprecated: data.GetJSON was deprecated in Hugo v0.123.0 and will be removed in Hugo 0.138.0. use resources.Get or resources.GetRemote with transform.Unmarshal.
The funny things is I do not use data.GetJSON any where the only place I use getJSON is in the below partial.
Second, because you are accessing a remote resource, you need to use the resources.GetRemote function instead of data.GetJSON. The first example in the Remote data section shows you exactly how to do that.
I am lost in the documentation which is showing me to do exactly as I have currently done it using getJSON, but the Hugo build is failing.
So based on this what I need to change in below code as my understanding is that the code is exactly as Hugo wants it to be or I am missing the point here.
OK, what happens when the server doesn’t respond? Or when the api key expires?
Error checking is really, really important. Coding is a garbage-in garbage-out exercise. I suggest you reconsider your choice and take some time to understand the “way complicated” example.
There’s a reason the documented example includes error checking.