Added pre-initialization hook