Commit 9bb39cf2 authored by Tien-Thinh Nguyen's avatar Tien-Thinh Nguyen

Fix issue for sending notifications

parent 2965d644
...@@ -466,17 +466,12 @@ void nrf_app::handle_create_subscription( ...@@ -466,17 +466,12 @@ void nrf_app::handle_create_subscription(
subscription_condition_t sub_condition = {}; subscription_condition_t sub_condition = {};
ss.get()->get_sub_condition(sub_condition); ss.get()->get_sub_condition(sub_condition);
find_nf_profiles(sub_condition, profiles); find_nf_profiles(sub_condition, profiles);
if (profiles.size() > 0) { std::vector<std::string> notification_uris = {};
std::vector<std::string> notification_uris = {}; notification_uris.push_back(notification_uri);
notification_uris.push_back(notification_uri); for (auto p : profiles) {
// send notifications
for (auto p : profiles) { nrf_client_inst->notify_subscribed_event(
// send notifications p, NOTIFICATION_TYPE_NF_REGISTERED, notification_uris);
nrf_client_inst->notify_subscribed_event(
p, NOTIFICATION_TYPE_NF_REGISTERED, notification_uris);
}
} else {
Logger::nrf_app().error("\tNo NF profile found");
} }
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment