28 lines
495 B
Go
28 lines
495 B
Go
package member
|
|
|
|
import (
|
|
"context"
|
|
"fmt"
|
|
|
|
"net/url"
|
|
|
|
"git.loafle.net/overflow/overflow_server_app/external/grpc"
|
|
"github.com/valyala/fasthttp"
|
|
)
|
|
|
|
func CheckEmail(ctx *fasthttp.RequestCtx) {
|
|
key := string(ctx.FormValue("key"))
|
|
|
|
params := []string{url.QueryEscape(key)}
|
|
|
|
gRPCCtx := context.Background()
|
|
r, err := grpc.Exec(gRPCCtx, "EmailAuthService.readByAuthKey", params)
|
|
|
|
if err != nil {
|
|
fmt.Fprintf(ctx, "Error!!!!: %s\n", err)
|
|
}
|
|
|
|
fmt.Fprintf(ctx, "Email Check!!!!: %s\n", r)
|
|
|
|
}
|