Browse Source

Merge pull request #7334 from qbittorrent/fix-7333

Fix RSS Downloader fails to rename rule. Closes #7333
adaptive-webui-19844
Vladimir Golovnev 7 years ago committed by GitHub
parent
commit
4cb304def8
  1. 4
      src/gui/rss/automatedrssdownloader.cpp

4
src/gui/rss/automatedrssdownloader.cpp

@ -692,8 +692,10 @@ void AutomatedRssDownloader::handleRuleAdded(const QString &ruleName)
void AutomatedRssDownloader::handleRuleRenamed(const QString &ruleName, const QString &oldRuleName) void AutomatedRssDownloader::handleRuleRenamed(const QString &ruleName, const QString &oldRuleName)
{ {
auto item = m_itemsByRuleName.value(oldRuleName); auto item = m_itemsByRuleName.take(oldRuleName);
m_itemsByRuleName.insert(ruleName, item); m_itemsByRuleName.insert(ruleName, item);
if (m_currentRule.name() == oldRuleName)
m_currentRule.setName(ruleName);
item->setText(ruleName); item->setText(ruleName);
} }

Loading…
Cancel
Save