Commit 75222dde authored by Nico Baruna Putra's avatar Nico Baruna Putra

remove error handler exit

parent 0cc82bed
......@@ -6,6 +6,7 @@ import (
"io/ioutil"
"log"
"net/http"
"os"
"os/exec"
"time"
......@@ -65,14 +66,14 @@ func main() {
func checkApi() {
response, _ := http.Get(BASE_URL + API_URL)
// if err != nil {
// fmt.Print(err.Error())
// sendMail("API not response")
// Native()
// //os.Exit(1)
response, err := http.Get(BASE_URL + API_URL)
if err != nil {
fmt.Print(err.Error())
sendMail("API not response")
Native()
os.Exit(1)
// }
}
if response.StatusCode != 200 {
sendMail("API not response")
Native()
......
No preview for this file type
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment