1
0
Fork 0
mirror of https://github.com/miniflux/v2.git synced 2025-08-11 17:51:01 +00:00

Improve API

This commit is contained in:
Frédéric Guillot 2017-12-24 18:04:34 -08:00
parent 3f473e4a09
commit d5b8f2fb88
15 changed files with 238 additions and 110 deletions

View file

@ -72,13 +72,14 @@ func (s *Storage) CreateUser(user *model.User) (err error) {
(username, password, is_admin, extra)
VALUES
($1, $2, $3, $4)
RETURNING id, language, theme, timezone`
RETURNING id, language, theme, timezone, entry_direction`
err = s.db.QueryRow(query, strings.ToLower(user.Username), password, user.IsAdmin, extra).Scan(
&user.ID,
&user.Language,
&user.Theme,
&user.Timezone,
&user.EntryDirection,
)
if err != nil {
return fmt.Errorf("unable to create user: %v", err)