Error 404 for image file (via pages) which exists in repository

I have a rather strange issue. There are two repositories, each has “docs” directory with content hosted via GitHub pages. I use a custom domain for that. However, some files (mostly images) are not accessable from one repo although they are visible from another one. Here is an example:

Raw file from one repo:

https://github.com/svkucheryavski/mdatools/blob/master/docs/_main_files/figure-html/unnamed-chunk-10-1.png

This file via Git Hub Pages:

http://mdatools.com/mdatools/_main_files/figure-html/unnamed-chunk-10-1.png

No problem. Now raw file in the other repo:

https://github.com/svkucheryavski/mdatools.bookdown/blob/master/docs/_main_files/figure-html/unnamed-chunk-10-1.png

Same name, same location, everything (except the repository name of course) is the same, however if I try to get it via pages I got 404:

http://mdatools.com/mdatools.bookdown/_main_files/figure-html/unnamed-chunk-10-1.png

Spend whole day reading forum, will be greatful for any help! I use .nojekyll in both cases.

Solved — file .nojekyll should be placed to the repository with main Github Pages content. Otherwise folders starting with underscore are not processed correctly.