georgringer / news

TYPO3 Extension news
GNU General Public License v2.0
265 stars 355 forks source link

Error viewing history after changing 'Template Layout' #2459

Closed PeGuIwelt closed 6 months ago

PeGuIwelt commented 6 months ago

Bug Report

Current Behavior I added an option to tx_news.templateLayouts as described in https://docs.typo3.org/p/georgringer/news/main/en-us/Reference/TsConfig/General.html#tsconfigTemplateLayouts:

tx_news {
    templateLayouts {
        1 = LatestArticles
    }
}

After saving a page object of type 'news article list' with a changed value in 'Plugin > Template > Template Layout' the history of the object cannot be viewed, the following error is displayed:

GeorgRinger\News\Hooks\ItemsProcFunc::getPageId(): Return value must be of type int, null returned

Environment

froemken commented 6 months ago

I had the same issue. On main branch it was already fixed with:

https://github.com/georgringer/news/commit/4c41691f9289bfd8a4ba2f07bafe6c4672ecaf84

PeGuIwelt commented 6 months ago

I can confirm that https://github.com/georgringer/news/commit/4c41691f9289bfd8a4ba2f07bafe6c4672ecaf84 fixes my problem, thx.