diff options
| author | Thibaut Horel <thibaut.horel@gmail.com> | 2018-12-28 18:57:07 -0500 |
|---|---|---|
| committer | Thibaut Horel <thibaut.horel@gmail.com> | 2018-12-28 18:57:07 -0500 |
| commit | 33389b0719c78de5fc5694a173f951b3666c183b (patch) | |
| tree | 57a3f2574d9173812d09b874aebcfd73a7358679 /store.go | |
| parent | 04cf96cdc3ef6c78b2d4754e3c8028b5c1c45fc0 (diff) | |
| download | id-33389b0719c78de5fc5694a173f951b3666c183b.tar.gz | |
Read database address from command line args
Diffstat (limited to 'store.go')
| -rw-r--r-- | store.go | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -28,8 +28,8 @@ type PgStore struct { sessionCache map[string]*Session } -func NewPgStore() *PgStore { - db, err := sql.Open("postgres", "postgres://auth_master:pass@localhost/authdb") +func NewPgStore(database string) *PgStore { + db, err := sql.Open("postgres", database) if err != nil { log.Panic(err) } |
