Skip to content

Commit

Permalink
simplify code generation
Browse files Browse the repository at this point in the history
  • Loading branch information
kevwan committed Oct 12, 2020
1 parent 84cc41d commit 936dd67
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions tools/goctl/rpc/gen/genmain.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,9 @@ func main() {
ctx := svc.NewServiceContext(c)
{{.srv}}
s, err := zrpc.NewServer(c.RpcServerConf, func(grpcServer *grpc.Server) {
s := zrpc.MustNewServer(c.RpcServerConf, func(grpcServer *grpc.Server) {
{{.registers}}
})
logx.Must(err)
defer s.Stop()
fmt.Printf("Starting rpc server at %s...\n", c.ListenOn)
Expand Down

0 comments on commit 936dd67

Please sign in to comment.