REF_NOT_FOUND when using content/posts/post1/index.md

Hello.

So, I had a directory structure of content/projects/post1.md. But, now, I wish to move it to content/projects/post1/index.md to use page bundles for image processing.

I tried that and started getting errors:

ERROR 2020/09/03 18:48:16 [en] REF_NOT_FOUND: Ref "index.en.md" from page "projects\\dropbox\\index.en.md": page not found

The same error repeats the same number of times as the number of headings in that post. Thus, I thought that it might be coming from my layout/partials/toc.html. After I removed the relref from that file, the error goes away, so, that was indeed the cause.

I read some common solution to this and so, just to clarify, none of my posts are draft or future. Also, the website works normally when I change the structure back to content/projects/post1.md.

I’m using Hugo Extended v0.74.3 on Windows 10 64-bit, by the way.

Here’s my project folder: https://github.com/gohugoio/hugo/files/5168647/Portfolio.zip

No:

{{ $base := ($.Page.File.LogicalName) }}

Yes:

{{ $base := $.Path }}

So, that’s one of the downsides of referring to older blog posts to help you with your code. Thanks for the help, that worked perfectly.