Fix build warnings

This commit fixes some build warnings in CI caused by unused variables
and an invalid move assignment operator, since a member variable is of
reference type.

Signed-off-by: John Wedig <johnwedig@google.com>
Change-Id: I2b813ef017e47f2d35666063435a52638b74d156
diff --git a/src/main.cpp b/src/main.cpp
index 2f93899..578d505 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -31,14 +31,14 @@
  * more types of storage devices.
  */
 void createStorageObjects(
-    boost::asio::io_context& io, sdbusplus::asio::object_server& objectServer,
+    sdbusplus::asio::object_server& objectServer,
     boost::container::flat_map<
         std::string, std::unique_ptr<estoraged::EStoraged>>& storageObjects,
     std::shared_ptr<sdbusplus::asio::connection>& dbusConnection)
 {
     auto getter = std::make_shared<estoraged::GetStorageConfiguration>(
         dbusConnection,
-        [&io, &objectServer, &storageObjects](
+        [&objectServer, &storageObjects](
             const estoraged::ManagedStorageType& storageConfigurations) {
             size_t numConfigObj = storageConfigurations.size();
             if (numConfigObj > 1)
@@ -124,9 +124,8 @@
                                    std::unique_ptr<estoraged::EStoraged>>
             storageObjects;
 
-        boost::asio::post(io, [&]() {
-            createStorageObjects(io, server, storageObjects, conn);
-        });
+        boost::asio::post(
+            io, [&]() { createStorageObjects(server, storageObjects, conn); });
 
         /*
          * Set up an event handler to process any new configuration objects
@@ -160,7 +159,7 @@
                             lg2::error("timer error");
                             return;
                         }
-                        createStorageObjects(io, server, storageObjects, conn);
+                        createStorageObjects(server, storageObjects, conn);
                     });
             };