Index: shell/src/SubscriptionsCommand.cpp |
=================================================================== |
--- a/shell/src/SubscriptionsCommand.cpp |
+++ b/shell/src/SubscriptionsCommand.cpp |
@@ -73,31 +73,31 @@ std::string SubscriptionsCommand::GetUsa |
void SubscriptionsCommand::ShowSubscriptions() |
{ |
ShowSubscriptionList(filterEngine.GetListedSubscriptions()); |
} |
void SubscriptionsCommand::AddSubscription(const std::string& url, |
const std::string& title) |
{ |
- AdblockPlus::Subscription& subscription = filterEngine.GetSubscription(url); |
+ AdblockPlus::SubscriptionPtr subscription = filterEngine.GetSubscription(url); |
if (title.size()) |
- subscription.SetProperty("title", title); |
- subscription.AddToList(); |
+ subscription->SetProperty("title", title); |
+ subscription->AddToList(); |
} |
void SubscriptionsCommand::RemoveSubscription(const std::string& url) |
{ |
- AdblockPlus::Subscription& subscription = filterEngine.GetSubscription(url); |
- if (!subscription.IsListed()) |
+ AdblockPlus::SubscriptionPtr subscription = filterEngine.GetSubscription(url); |
+ if (!subscription->IsListed()) |
{ |
std::cout << "No subscription with URL '" << url << "'" << std::endl; |
return; |
} |
- subscription.RemoveFromList(); |
+ subscription->RemoveFromList(); |
} |
void SubscriptionsCommand::UpdateSubscriptions() |
{ |
const SubscriptionList& subscriptions = filterEngine.GetListedSubscriptions(); |
for (SubscriptionList::const_iterator it = subscriptions.begin(); |
it != subscriptions.end(); it++) |
(*it)->UpdateFilters(); |