From 27611e7ad9c06ff4a07fbb5744798304e5fd72c1 Mon Sep 17 00:00:00 2001 From: Andrew Morgan Date: Wed, 6 Jun 2018 11:07:25 +0100 Subject: [PATCH] Don't forget to set the localpart --- .../clientapi/auth/storage/accounts/accounts_table.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/github.com/matrix-org/dendrite/clientapi/auth/storage/accounts/accounts_table.go b/src/github.com/matrix-org/dendrite/clientapi/auth/storage/accounts/accounts_table.go index 11f82498..0843f523 100644 --- a/src/github.com/matrix-org/dendrite/clientapi/auth/storage/accounts/accounts_table.go +++ b/src/github.com/matrix-org/dendrite/clientapi/auth/storage/accounts/accounts_table.go @@ -124,11 +124,11 @@ func (s *accountsStatements) selectPasswordHash( func (s *accountsStatements) selectAccountByLocalpart( ctx context.Context, localpart string, ) (*authtypes.Account, error) { - var localpartPtr, appserviceIDPtr sql.NullString + var appserviceIDPtr sql.NullString var acc authtypes.Account stmt := s.selectAccountByLocalpartStmt - err := stmt.QueryRowContext(ctx, localpart).Scan(&localpartPtr, &appserviceIDPtr) + err := stmt.QueryRowContext(ctx, localpart).Scan(&acc.Localpart, &appserviceIDPtr) if err != nil { switch err { case sql.ErrNoRows: