added guard against reloading the plugin