chore: adjust rpc comment format (#2501)
parent
c92a2d1b77
commit
22bdf0bbd5
@ -1,11 +1,15 @@
|
||||
package parser
|
||||
|
||||
import "github.com/emicklei/proto"
|
||||
import (
|
||||
"strings"
|
||||
|
||||
"github.com/emicklei/proto"
|
||||
)
|
||||
|
||||
// GetComment returns content with prefix //
|
||||
func GetComment(comment *proto.Comment) string {
|
||||
if comment == nil {
|
||||
return ""
|
||||
}
|
||||
return "// " + comment.Message()
|
||||
return "// " + strings.TrimSpace(comment.Message())
|
||||
}
|
||||
|
Loading…
Reference in New Issue