Make /installaddon possible to upgrade addon

This commit is contained in:
Benau 2021-10-01 14:23:47 +08:00
parent fa1ddbd839
commit 87fd3f221a

View File

@ -262,7 +262,8 @@ void AddonsPack::install(const std::string& name)
Addon* addon = addons_manager->getAddon(Addon::createAddonId(name));
if (addon)
{
if (addon->isInstalled())
if (addon->isInstalled() &&
addon->getRevision() == addon->getInstalledRevision())
{
if (nl)
nl->addMoreServerInfo(L"Addon already installed");