Fixed issues caused by new encodingKludge code that was causing errors to be thrown due to function structure being incorrect.
Merge tag 'v3.9.2' into develop

Tagging version v3.9.2 v3.9.2