We have setup new IIS and Moodle 3.1 and it was working fine. Currently, we have updated some code and pulled on the server. Now images are not displaying properly. We are guessing it might be because of permission changes or encoding changes for some files. But It is difficult to find what is exact issue. On loading page, we are getting the Encoding issue in the console.
What is a permanent solution for this? It will be difficult if we face the same issue on the production server and it will difficult to upload images again.
It might be similar to https://moodle.org/mod/forum/discuss.php?d=316549
So please guide how we can solve this issue