commons clean up

Change-Id: I13ce15666974e294d2645768dd20194f0584d406
diff --git a/src/protocol-detail/error.cpp b/src/protocol-detail/error.cpp
index 79dc535..266e4e6 100644
--- a/src/protocol-detail/error.cpp
+++ b/src/protocol-detail/error.cpp
@@ -27,8 +27,8 @@
 ErrorTLV::encodeDataContent(ErrorCode errorCode, const std::string& description)
 {
   Block response = makeEmptyBlock(tlv::Content);
-  response.push_back(makeNonNegativeIntegerBlock(tlv_error_code, static_cast<size_t>(errorCode)));
-  response.push_back(makeStringBlock(tlv_error_info, description));
+  response.push_back(makeNonNegativeIntegerBlock(tlv::ErrorCode, static_cast<size_t>(errorCode)));
+  response.push_back(makeStringBlock(tlv::ErrorInfo, description));
   response.encode();
   return response;
 }
@@ -37,11 +37,11 @@
 ErrorTLV::decodefromDataContent(const Block& block)
 {
   block.parse();
-  if (block.find(tlv_error_code) == block.elements_end()) {
+  if (block.find(tlv::ErrorCode) == block.elements_end()) {
     return std::make_tuple(ErrorCode::NO_ERROR, "");
   }
-  ErrorCode error = static_cast<ErrorCode>(readNonNegativeInteger(block.get(tlv_error_code)));
-  return std::make_tuple(error, readString(block.get(tlv_error_info)));
+  ErrorCode error = static_cast<ErrorCode>(readNonNegativeInteger(block.get(tlv::ErrorCode)));
+  return std::make_tuple(error, readString(block.get(tlv::ErrorInfo)));
 }
 
 } // namespace ndncert