diff --git a/writenopcloser.go b/writenopcloser.go new file mode 100644 index 0000000..b19d4f1 --- /dev/null +++ b/writenopcloser.go @@ -0,0 +1,17 @@ +package raft + +import ( + "io" +) + +type internalWriteNopCloser struct { + writer io.Writer +} + +func (receiver internalWriteNopCloser) Write(p []byte) (n int, err error) { + return receiver.writer.Write(p) +} + +func (internalWriteNopCloser) Close() error { + return nil +}