Menu-specific template loads correctly.

Solution to menu-specific template not being loaded when joomla override plugin is enabled.

It appears that the menu-specific template is not available until onAfterRoute is triggered (onAfterInitialise results in the default template name being returned even though a different template has been defined in the menu item assignment).

Most probably results from the client request not being available until onAfterRoute is fired; i.e. what the user has requested (itemId) has not been made available to the getTemplate method therefore it falls back to the default template.