diff --git a/web/backto.go b/web/backto.go index 7365b405..43ba2d50 100644 --- a/web/backto.go +++ b/web/backto.go @@ -16,13 +16,8 @@ var hostnameWhitelist = map[string]bool{ func isWhitelisted(hostname string) bool { fmt.Printf("hostname: %v\n", hostname) - regex, err := regexp.Compile("pr-(\\d+)-appmain-bplesliplq-uc.a.run.app") - if err != nil { - fmt.Errorf("Error compiling regex for whitelisted hostnames: %+v", err) - return false - } - - if regex.MatchString(hostname) { + isPRTempEnv, _ := regexp.MatchString("pr-(\\d+)-appmain-bplesliplq-uc.a.run.app", hostname) + if isPRTempEnv { return true }