Tom,
I discovered today my homepage had no h1 tag.
I found this code in the support form.
However, my homepage is built using sections. For some reason it my home page isn’t recognized at the homepage even though it is set has homepage in Settings – Reading. I had to change the is_home to is_page (page id) to get the code to work.
I’m guessing this has something to do with the page being built with sections.
Thought I’d post this in case anyone else is running into an issue of no h1 tag on their homepage using sections.