diff options
| author | Arda Serdar Pektezol <1669855+pektezol@users.noreply.github.com> | 2024-07-04 19:02:11 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-07-04 19:02:11 +0300 |
| commit | 368f6dd461d768e835124afdd5aa0228d9e0ba0b (patch) | |
| tree | 4b78a4571f6cc4b7e0f553d90f52c016c9d2b8e1 /main.go | |
| parent | fix: fetchmaps image sql (diff) | |
| download | lphub-368f6dd461d768e835124afdd5aa0228d9e0ba0b.tar.gz lphub-368f6dd461d768e835124afdd5aa0228d9e0ba0b.tar.bz2 lphub-368f6dd461d768e835124afdd5aa0228d9e0ba0b.zip | |
feat: update map tables db schema (#157)
Diffstat (limited to '')
| -rw-r--r-- | main.go | 6 |
1 files changed, 3 insertions, 3 deletions
| @@ -22,13 +22,13 @@ import ( | |||
| 22 | // @host lp.ardapektezol.com | 22 | // @host lp.ardapektezol.com |
| 23 | // @BasePath /api/v1 | 23 | // @BasePath /api/v1 |
| 24 | func main() { | 24 | func main() { |
| 25 | if os.Getenv("ENV") == "PROD" { | ||
| 26 | gin.SetMode(gin.ReleaseMode) | ||
| 27 | } | ||
| 28 | err := godotenv.Load() | 25 | err := godotenv.Load() |
| 29 | if err != nil { | 26 | if err != nil { |
| 30 | log.Fatal("Error loading .env file") | 27 | log.Fatal("Error loading .env file") |
| 31 | } | 28 | } |
| 29 | if os.Getenv("ENV") == "PROD" { | ||
| 30 | gin.SetMode(gin.ReleaseMode) | ||
| 31 | } | ||
| 32 | router := gin.Default() | 32 | router := gin.Default() |
| 33 | database.ConnectDB() | 33 | database.ConnectDB() |
| 34 | api.InitRoutes(router) | 34 | api.InitRoutes(router) |