In one fo our websites we noticed that the JSON output of the posts was incorrect. The plugin was printing the JSON schema of other posts than the current one. After digging into the plugin code we saw that in lib/classes/KcSeoOutput.php you are doing this http://prntscr.com/lxp8lf/ in order to reset a possibly non reset loop.
However, in our case, for some reason this does not seem to be enough and another post’s JSON schema is printed!
Instead of doing what you do, I propose you do not do it at all and grab the current post by using the get_queried_object() function like this http://prntscr.com/lxpazv/. It is quicker, simpler and does not care about any possible loop or query problems which are difficult to debug through WordPress actions and filters.
I would love to see this in the next version of the plugin, as we have patched its core code as mentioned above for the moment. What do you think?
I see that version 1.2.4 is out and I was wondering if a fix for the issue mentioned above has been included? It is really kinda important to us because, at the time being, we have been forced to tamper with the core code of the plugin in order to overcome it.