Corrected initialisation of plugin