瀏覽代碼

Shorten lambda statement

Nick Babcock 7 年之前
父節點
當前提交
012592e7d5
共有 1 個文件被更改,包括 1 次插入4 次删除
  1. 1 4
      OhmGraphite/Program.cs

+ 1 - 4
OhmGraphite/Program.cs

@@ -40,10 +40,7 @@ namespace OhmGraphite
                 x.SetDescription("Extract hardware sensor data and exports it to a given host and port in a graphite compatible format");
                 x.SetDisplayName("Ohm Graphite");
                 x.SetServiceName("OhmGraphite");
-                x.OnException(ex =>
-                {
-                    Logger.Error(ex, "OhmGraphite TopShelf encountered an error");
-                });
+                x.OnException(ex => Logger.Error(ex, "OhmGraphite TopShelf encountered an error"));
             });
         }