Sfoglia il codice sorgente

Simplify the NopWriter code.

Caleb Spare 12 anni fa
parent
commit
27ee261e60
1 ha cambiato i file con 2 aggiunte e 3 eliminazioni
  1. 2 3
      utils/utils.go

+ 2 - 3
utils/utils.go

@@ -170,10 +170,9 @@ func SelfPath() string {
 	return path
 }
 
-type NopWriter struct {
-}
+type NopWriter struct{}
 
-func (w *NopWriter) Write(buf []byte) (int, error) {
+func (*NopWriter) Write(buf []byte) (int, error) {
 	return len(buf), nil
 }