diff --git a/src/logic.cpp b/src/logic.cpp
index a8cd68e..88cd502 100644
--- a/src/logic.cpp
+++ b/src/logic.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil -*- */
 /*
- * Copyright (c) 2012-2019 University of California, Los Angeles
+ * Copyright (c) 2012-2020 University of California, Los Angeles
  *
  * This file is part of ChronoSync, synchronization library for distributed realtime
  * applications for NDN.
@@ -290,7 +290,6 @@
         insertToDiffLog(commit, previousRoot);
 
         satisfyPendingSyncInterests(prefix, commit);
-        // formAndSendExcludeInterest(prefix, *commit, previousRoot);
       }
     }
   }
@@ -455,7 +454,7 @@
     return;
   }
 
-  DiffStateContainer::iterator stateIter = m_log.find(digest);
+  auto stateIter = m_log.find(digest);
   // If the digest of incoming interest can be found from the log
   if (stateIter != m_log.end()) {
     _LOG_DEBUG_ID("It is ok, you are so close");
@@ -490,9 +489,7 @@
 }
 
 void
-Logic::processSyncData(const Name& name,
-                       ConstBufferPtr digest,
-                       const Block& syncReplyBlock)
+Logic::processSyncData(const Name& name, ConstBufferPtr digest, const Block& syncReply)
 {
   _LOG_DEBUG_ID(">> Logic::processSyncData");
   DiffStatePtr commit = make_shared<DiffState>();
@@ -502,7 +499,7 @@
     m_interestTable.erase(digest); // Remove satisfied interest from PIT
 
     State reply;
-    reply.wireDecode(syncReplyBlock);
+    reply.wireDecode(syncReply);
 
     std::vector<MissingDataInfo> v;
     BOOST_FOREACH(ConstLeafPtr leaf, reply.getLeaves().get<ordered>()) {
@@ -778,16 +775,15 @@
 
   Name name = interest.getName();
   ConstBufferPtr digest = make_shared<ndn::Buffer>(name.get(-1).value(), name.get(-1).value_size());
-
   ConstBufferPtr rootDigest = m_state.getRootDigest();
 
-  DiffStateContainer::iterator stateIter = m_log.find(digest);
-
+  auto stateIter = m_log.find(digest);
   if (stateIter != m_log.end() || *digest == *EMPTY_DIGEST || *rootDigest == *digest) {
     _LOG_DEBUG_ID("I can help you recover");
     sendSyncData(m_defaultUserPrefix, name, m_state);
     return;
   }
+
   _LOG_DEBUG_ID("<< Logic::processRecoveryInterest");
 }
 
diff --git a/src/logic.hpp b/src/logic.hpp
index b363e9d..bd5d3db 100644
--- a/src/logic.hpp
+++ b/src/logic.hpp
@@ -1,6 +1,6 @@
 /* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil -*- */
 /*
- * Copyright (c) 2012-2019 University of California, Los Angeles
+ * Copyright (c) 2012-2020 University of California, Los Angeles
  *
  * This file is part of ChronoSync, synchronization library for distributed realtime
  * applications for NDN.
@@ -365,24 +365,21 @@
    * This method extracts state update information from Sync Reply and applies
    * it to the Sync Tree and re-express Sync Interest.
    *
-   * @param name           The data name of the Sync Reply.
-   * @param digest         The digest in the data name.
-   * @param syncReplyBlock The content of the Sync Reply.
+   * @param name      The data name of the Sync Reply.
+   * @param digest    The digest in the data name.
+   * @param syncReply The content of the Sync Reply.
    */
   void
-  processSyncData(const Name& name,
-                  ConstBufferPtr digest,
-                  const Block& syncReplyBlock);
+  processSyncData(const Name& name, ConstBufferPtr digest, const Block& syncReply);
 
   /**
    * @brief Insert state diff into log
    *
-   * @param diff         The diff .
+   * @param diff         The diff.
    * @param previousRoot The root digest before state changes.
    */
   void
-  insertToDiffLog(DiffStatePtr diff,
-                  ConstBufferPtr previousRoot);
+  insertToDiffLog(DiffStatePtr diff, ConstBufferPtr previousRoot);
 
   /**
    * @brief Reply to all pending Sync Interests with a particular commit (or diff)
@@ -457,32 +454,6 @@
   void
   onRecoveryTimeout(const Interest& interest);
 
-  // /**
-  //  * @brief Helper method to send Exclude Interest
-  //  *
-  //  * @param interest    The interest whose exclude filter will be augmented
-  //  * @param data        The data whose implicit digest will be inserted into exclude filter
-  //  */
-  // void
-  // sendExcludeInterest(const Interest& interest, const Data& data);
-
-  // /**
-  //  * @brief Helper method to form the exclude Interest and calls sendExcludeInterest
-  //  *
-  //  * @param interest       The interest whose exclude filter will be augmented
-  //  * @param nodePrefix     The prefix of the sender node
-  //  * @param commit         The commit whose contents will be used to obtain the implicit
-  //                          digest to be excluded
-  //  * @param previousRoot   The digest to be included in the interest
-  //  */
-  // void
-  // formAndSendExcludeInterest(const Name& nodePrefix,
-  //                            const State& commit,
-  //                            ConstBufferPtr previousRoot);
-
-  void
-  cleanupPendingInterest(const ndn::PendingInterestId* pendingInterestId);
-
 public:
   static const ndn::Name DEFAULT_NAME;
   static const ndn::Name EMPTY_NAME;
