forked from an/flokati
fixed careless mistakes
This commit is contained in:
parent
41be481497
commit
f0cbc1785f
|
@ -24,7 +24,7 @@ func init() {
|
||||||
func webhookRun() {
|
func webhookRun() {
|
||||||
xlog.Info("webhook listener started")
|
xlog.Info("webhook listener started")
|
||||||
http.HandleFunc("/webhook", webhookHandleHTTP)
|
http.HandleFunc("/webhook", webhookHandleHTTP)
|
||||||
xlog.Fatal(http.ListenAndServe(":"+*webhookPort, nil))
|
xlog.Fatal("%v", http.ListenAndServe(":"+*webhookPort, nil))
|
||||||
}
|
}
|
||||||
|
|
||||||
func webhookHandleHTTP(w http.ResponseWriter, r *http.Request) {
|
func webhookHandleHTTP(w http.ResponseWriter, r *http.Request) {
|
||||||
|
@ -38,7 +38,7 @@ func webhookHandleHTTP(w http.ResponseWriter, r *http.Request) {
|
||||||
for k, v := range data {
|
for k, v := range data {
|
||||||
fmt.Printf("%s : %v\n", k, v)
|
fmt.Printf("%s : %v\n", k, v)
|
||||||
if k == "text" {
|
if k == "text" {
|
||||||
sayCh <- *webhookChan + "\n" + v
|
SayCh <- fmt.Printf("%s\n%v", *webhookChan, v)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue