Auto-création du compte utilisateur à la première connexion

- Sauvegarde de l'adresse courriel de l'utilisateur en session
- Implémentation d'une première Query GraphQL pour récupérer le profil
  de l'utilisateur connecté
- Utilisation de la pattern CQRS pour les commandes/requêtes sur la base
  de données
This commit is contained in:
2020-07-13 14:44:05 +02:00
parent a096b506e2
commit 3fd8bf7e69
11 changed files with 395 additions and 7 deletions

View File

@ -8,7 +8,7 @@ import (
const ServiceName service.Name = "database"
// From retrieves the database pool service in the given container
// From retrieves the database pool service in the given container.
func From(container *service.Container) (*pgxpool.Pool, error) {
service, err := container.Service(ServiceName)
if err != nil {
@ -23,7 +23,7 @@ func From(container *service.Container) (*pgxpool.Pool, error) {
return srv, nil
}
// Must retrieves the database pool service in the given container or panic otherwise
// Must retrieves the database pool service in the given container or panic otherwise.
func Must(container *service.Container) *pgxpool.Pool {
srv, err := From(container)
if err != nil {