Skip to content

Commit 1e2003c

Browse files
committed
fix typo
1 parent 138fe99 commit 1e2003c

File tree

4 files changed

+7
-7
lines changed

4 files changed

+7
-7
lines changed

pkg/environement/check_environment_variables.go renamed to pkg/environment/check_environment_variables.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package environement
1+
package environment
22

33
import (
44
"errors"

pkg/mysql/connect_mysql.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ package mysql
22

33
import (
44
"fmt"
5-
"github.com/SbstnErhrdt/go-gorm-all-sql/pkg/environement"
5+
"github.com/SbstnErhrdt/go-gorm-all-sql/pkg/environment"
66
"gorm.io/driver/mysql"
77
"gorm.io/gorm"
88
"log"
@@ -19,7 +19,7 @@ var requiredEnvironmentVariablesForMySQL = []string{
1919

2020
func ConnectToMysql(config *gorm.Config) (client *gorm.DB, err error) {
2121
// check env variables
22-
environement.CheckEnvironmentVariables(requiredEnvironmentVariablesForMySQL)
22+
environment.CheckEnvironmentVariables(requiredEnvironmentVariablesForMySQL)
2323
// env variables
2424
host := os.Getenv("SQL_HOST")
2525
user := os.Getenv("SQL_USER")

pkg/postgres/connect_postgres.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ package postgres
22

33
import (
44
"fmt"
5-
"github.com/SbstnErhrdt/go-gorm-all-sql/pkg/environement"
5+
"github.com/SbstnErhrdt/go-gorm-all-sql/pkg/environment"
66
"gorm.io/driver/postgres"
77
"gorm.io/gorm"
88
"log"
@@ -20,7 +20,7 @@ var requiredEnvironmentVariablesForPostGres = []string{
2020
// Creates a connection to a postgres database
2121
func ConnectToPostgres(config *gorm.Config) (client *gorm.DB, err error) {
2222
// check env variables
23-
environement.CheckEnvironmentVariables(requiredEnvironmentVariablesForPostGres)
23+
environment.CheckEnvironmentVariables(requiredEnvironmentVariablesForPostGres)
2424
// required env variables
2525
host := os.Getenv("SQL_HOST")
2626
user := os.Getenv("SQL_USER")

pkg/sqlite/connect_sqlite.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
package sqlite
22

33
import (
4-
"github.com/SbstnErhrdt/go-gorm-all-sql/pkg/environement"
4+
"github.com/SbstnErhrdt/go-gorm-all-sql/pkg/environment"
55
"gorm.io/driver/sqlite"
66
"gorm.io/gorm"
77
"log"
@@ -14,7 +14,7 @@ var requiredEnvironmentVariablesForSQLite = []string{
1414

1515
func ConnectToSQLite(config *gorm.Config) (client *gorm.DB, err error) {
1616
// check env variables
17-
environement.CheckEnvironmentVariables(requiredEnvironmentVariablesForSQLite)
17+
environment.CheckEnvironmentVariables(requiredEnvironmentVariablesForSQLite)
1818
dbName := os.Getenv("SQL_DATABASE")
1919
// connect to database
2020
client, err = gorm.Open(sqlite.Open(dbName), config)

0 commit comments

Comments
 (0)