implement install and uninstall of plugin AddExternalPagesPlugin : and reorder code