Replace ndnsType with NdnsContentType

Change-Id: I74afe92d31e78d80404816113063d7f996d666c5
diff --git a/src/daemon/name-server.cpp b/src/daemon/name-server.cpp
index ab3356c..70288ec 100644
--- a/src/daemon/name-server.cpp
+++ b/src/daemon/name-server.cpp
@@ -103,14 +103,11 @@
   }
   else {
     // no record, construct NACK
-    Block block = makeNonNegativeIntegerBlock(tlv::NdnsType, NDNS_NACK);
-    MetaInfo info;
-    info.addAppMetaInfo(block);
-    info.setFreshnessPeriod(this->getContentFreshness());
     Name name = interest.getName();
     name.appendVersion();
     shared_ptr<Data> answer = make_shared<Data>(name);
-    answer->setMetaInfo(info);
+    answer->setFreshnessPeriod(this->getContentFreshness());
+    answer->setContentType(NDNS_NACK);
 
     m_keyChain.sign(*answer, m_certName);
     NDNS_LOG_TRACE("answer query with NDNS-NACK: " << answer->getName());
@@ -168,14 +165,11 @@
   rrset.setLabel(re.rrLabel);
   rrset.setType(re.rrType);
 
-  Block ndnsType = makeNonNegativeIntegerBlock(::ndn::ndns::tlv::NdnsType, NDNS_RESP);
-  MetaInfo info;
-  info.addAppMetaInfo(ndnsType);
-  info.setFreshnessPeriod(this->getContentFreshness());
   Name name = interest->getName();
   name.appendVersion();
   shared_ptr<Data> answer = make_shared<Data>(name);
-  answer->setMetaInfo(info);
+  answer->setFreshnessPeriod(this->getContentFreshness());
+  answer->setContentType(NDNS_RESP);
 
   Block blk(ndn::ndns::tlv::RrData);
   try {