There seem to be some wrong declarations in simplenews' hook_theme implementation.
In 2394 - 2397 the path to the file containing the theme function is wrong. For this one I attach a patch.
The resulting warning that I saw only when trying to run update.php:
warning: include_once(sites/all/modules/simplenews/theme/includes/simplenews.admin.inc) [function.include-once]: failed to open stream: No such file or directory in /Users/ralf/Sites/Interactum/gk.interactum.de/includes/theme.inc on line 286.
In line 2374 - 2375 the simplenews_status theme uses a template and a file. I'm not sure if that is wrong, but it seems strange to me.
I post this for the dev version, but I see the problem also in the alpha2 version that I just tried to install.
| Comment | File | Size | Author |
|---|---|---|---|
| simplenews-6.x-theme-declarations.patch | 496 bytes | berliner |
Comments
Comment #1
simon georges commentedJust changing the status, as there is a patch attached.
Comment #2
simon georges commented@berliner, did you try to clear your theme registry ? There has been changes since the 6.x-1.x branch regarding the files of the theme.
Comment #3
berliner commentedNothing to do with the cache IMO. If you look at the declaration for theme_simplenews_subscription_list:
then you can see the the included file is simplenews.admin.inc which is located in simplenews/includes, but the given path for the inclusion is simplenews/theme, which results in simplenews/theme/includes/simplenews.admin.inc which generates the warning of my original post. I don't know though why this only happens when running update.php (at least I only saw it at that moment), but the declaration in itself seems wrong.
Another thing concerns the theme declaration for theme_simplenews_status. No path has been given where the template file should be searched making it probably harder for themes to use their own copy of the template. I'm not sure about that (and I have not the time to test unfortunately) but my experience tells me to always use the path attribute when you want a maximum of flexibility.
Comment #4
simon georges commentedCan somebody else confirm this?
Comment #5
joel_guesclin commentedI get this error when installing the module
Comment #6
berdirChange looks good to me.
This theme function does not exist in 7.x-1.x but here is a similar one from the 7.x-1.x branch:
Comment #7
simon georges commentedFixed in 6.x-2.x-dev. Thanks!