Active
Project:
Spaces
Version:
7.x-3.x-dev
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
2 Jan 2012 at 19:27 UTC
Updated:
2 Jan 2012 at 19:30 UTC
Jump to comment: Most recent file
What reason might we have to do such a thing? It seems it's helpful in providing a custom theme.
hook_init is invoked after hook_custom_theme, which means we don't have an active space when the theme is determined. If in our site we put a call to spaces_init() in our implementation of hook_custom_theme, then we can use the active space to set the theme.
Currently, that causes the code in spaces_init() to run twice, because it's executed when hook_init is invoked. It's probably a good idea to let it run only once (unless you've got a reason to force it to reinitialize). Sound good?
| Comment | File | Size | Author |
|---|---|---|---|
| #1 | prevent_spaces_init_running_twice-1391918-1.patch | 599 bytes | michaek |
Comments
Comment #1
michaek commented