Browse Source

Add comments

Rod Hynes 9 years ago
parent
commit
23c563002a
1 changed files with 4 additions and 2 deletions
  1. 4 2
      psiphon/notice.go

+ 4 - 2
psiphon/notice.go

@@ -502,12 +502,14 @@ func NewNoticeConsoleRewriter(writer io.Writer) *NoticeReceiver {
 	})
 }
 
-// ...
+// NoticeWriter implements io.Writer and emits the contents of Write() calls
+// as Notices. This is to transform logger messages, if they can be redirected
+// to an io.Writer, to notices.
 type NoticeWriter struct {
 	noticeType string
 }
 
-// ...
+// NewNoticeWriter initializes a new NoticeWriter
 func NewNoticeWriter(noticeType string) *NoticeWriter {
 	return &NoticeWriter{noticeType: noticeType}
 }