privetd: Remove empty device name checks

Server allows to have empty name. Buffet and privet also has no
requirement to have it not empty.

BUG=brillo:989
CQ-DEPEND=CL:274924
TEST=`FEATURES=test emerge-gizmo privetd buffet`

Change-Id: I02e141149d6eaf36a6c92676e68ab02b8287c724
Reviewed-on: https://chromium-review.googlesource.com/274883
Reviewed-by: Vitaly Buka <vitalybuka@chromium.org>
Tested-by: Vitaly Buka <vitalybuka@chromium.org>
Commit-Queue: Vitaly Buka <vitalybuka@chromium.org>
diff --git a/buffet/buffet_config.cc b/buffet/buffet_config.cc
index bf8891e..dc3ae97 100644
--- a/buffet/buffet_config.cc
+++ b/buffet/buffet_config.cc
@@ -128,6 +128,8 @@
   if (store.GetString(config_keys::kBackupPollingPeriodMs, &polling_period_str))
     CHECK(base::StringToUint64(polling_period_str, &backup_polling_period_ms_));
 
+  // Empty name set by user or server is allowed, still we expect some
+  // meaningfull config value.
   store.GetString(config_keys::kName, &name_);
   CHECK(!name_.empty());
 
@@ -228,15 +230,6 @@
   Commit();
 }
 
-bool BuffetConfig::Transaction::set_name(const std::string& name) {
-  if (name.empty()) {
-    LOG(ERROR) << "Invalid name: " << name;
-    return false;
-  }
-  config_->name_ = name;
-  return true;
-}
-
 bool BuffetConfig::Transaction::set_local_anonymous_access_role(
     const std::string& role) {
   if (!IsValidAccessRole(role)) {