mirror of https://github.com/statping/statping
removing api_key (unused)
parent
d9e3cabb4e
commit
73c3366625
|
@ -38,7 +38,6 @@ func apiIndexHandler(r *http.Request) interface{} {
|
||||||
|
|
||||||
func apiRenewHandler(w http.ResponseWriter, r *http.Request) {
|
func apiRenewHandler(w http.ResponseWriter, r *http.Request) {
|
||||||
var err error
|
var err error
|
||||||
core.App.ApiKey = utils.NewSHA256Hash()
|
|
||||||
core.App.ApiSecret = utils.NewSHA256Hash()
|
core.App.ApiSecret = utils.NewSHA256Hash()
|
||||||
err = core.App.Update()
|
err = core.App.Update()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
|
@ -47,7 +47,6 @@ func (c *Core) Create() error {
|
||||||
Name: c.Name,
|
Name: c.Name,
|
||||||
Description: c.Description,
|
Description: c.Description,
|
||||||
ConfigFile: utils.Directory + "/config.yml",
|
ConfigFile: utils.Directory + "/config.yml",
|
||||||
ApiKey: utils.RandomString(32),
|
|
||||||
ApiSecret: secret,
|
ApiSecret: secret,
|
||||||
Version: App.Version,
|
Version: App.Version,
|
||||||
Domain: c.Domain,
|
Domain: c.Domain,
|
||||||
|
|
|
@ -17,7 +17,6 @@ func Samples() error {
|
||||||
core := &Core{
|
core := &Core{
|
||||||
Name: "Statping Sample Data",
|
Name: "Statping Sample Data",
|
||||||
Description: "This data is only used to testing",
|
Description: "This data is only used to testing",
|
||||||
ApiKey: apiKey,
|
|
||||||
ApiSecret: apiSecret,
|
ApiSecret: apiSecret,
|
||||||
Domain: "http://localhost:8080",
|
Domain: "http://localhost:8080",
|
||||||
CreatedAt: utils.Now(),
|
CreatedAt: utils.Now(),
|
||||||
|
|
|
@ -232,8 +232,6 @@ func CheckHttp(s *Service, record bool) *Service {
|
||||||
headers = strings.Split(s.Headers.String, ",")
|
headers = strings.Split(s.Headers.String, ",")
|
||||||
} else {
|
} else {
|
||||||
headers = nil
|
headers = nil
|
||||||
log.Warnf("Custom set Headers are not valid for Server '%s'!\n",
|
|
||||||
s.Name)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// check if 'Content-Type' header was defined
|
// check if 'Content-Type' header was defined
|
||||||
|
|
Loading…
Reference in New Issue