diff --git a/daemon/fw/self-learning-strategy.cpp b/daemon/fw/self-learning-strategy.cpp
index ea32709..59a3f8f 100644
--- a/daemon/fw/self-learning-strategy.cpp
+++ b/daemon/fw/self-learning-strategy.cpp
@@ -149,13 +149,17 @@
 {
   for (auto& outFace : this->getFaceTable() | boost::adaptors::reversed) {
     if ((outFace.getId() == inFace.getId() && outFace.getLinkType() != ndn::nfd::LINK_TYPE_AD_HOC) ||
-        wouldViolateScope(inFace, interest, outFace) || outFace.getScope() == ndn::nfd::FACE_SCOPE_LOCAL) {
+        wouldViolateScope(inFace, interest, outFace) ||
+        outFace.getScope() == ndn::nfd::FACE_SCOPE_LOCAL) {
       continue;
     }
-    this->sendInterest(pitEntry, outFace, interest);
-    pitEntry->getOutRecord(outFace)->insertStrategyInfo<OutRecordInfo>().first->isNonDiscoveryInterest = false;
-    NFD_LOG_DEBUG("send discovery Interest=" << interest << " from="
-                  << inFace.getId() << " to=" << outFace.getId());
+
+    NFD_LOG_DEBUG("send discovery Interest=" << interest << " from=" << inFace.getId() <<
+                  " to=" << outFace.getId());
+    auto outRecord = this->sendInterest(pitEntry, outFace, interest);
+    if (outRecord != nullptr) {
+      outRecord->insertStrategyInfo<OutRecordInfo>().first->isNonDiscoveryInterest = false;
+    }
   }
 }
 
@@ -165,15 +169,17 @@
                                         const fib::NextHopList& nexthops)
 {
   for (const auto& nexthop : nexthops) {
-    Face& outFace = nexthop.getFace();
-    if ((outFace.getId() == inFace.getId() && outFace.getLinkType() != ndn::nfd::LINK_TYPE_AD_HOC) ||
-        wouldViolateScope(inFace, interest, outFace)) {
+    if (!isNextHopEligible(inFace, interest, nexthop, pitEntry)) {
       continue;
     }
-    this->sendInterest(pitEntry, outFace, interest);
-    pitEntry->getOutRecord(outFace)->insertStrategyInfo<OutRecordInfo>().first->isNonDiscoveryInterest = true;
-    NFD_LOG_DEBUG("send non-discovery Interest=" << interest << " from="
-                  << inFace.getId() << " to=" << outFace.getId());
+
+    Face& outFace = nexthop.getFace();
+    NFD_LOG_DEBUG("send non-discovery Interest=" << interest << " from=" << inFace.getId() <<
+                  " to=" << outFace.getId());
+    auto outRecord = this->sendInterest(pitEntry, outFace, interest);
+    if (outRecord != nullptr) {
+      outRecord->insertStrategyInfo<OutRecordInfo>().first->isNonDiscoveryInterest = true;
+    }
   }
 }
 
