func (ur *UserRepository) GetOne(ctx context.Context, id uint) (user.User, error) {
	q := `
	SELECT id, first_name, last_name, username, email, picture,
		created_at, updated_at
		FROM users WHERE id = $1;
	`

	row := ur.Data.DB.QueryRowContext(ctx, q, id)

	var u user.User
	err := row.Scan(&u.ID, &u.FirstName, &u.LastName, &u.Username, &u.Email,
		&u.Picture, &u.CreatedAt, &u.UpdatedAt)
	if err != nil {
		return user.User{}, err
	}

	return u, nil
}
// GetOne returns one user by id.
GetOne returns one user by id.
// GetOne returns one user by id .
func (ur *UserRepository) GetOne(ctx context.Context, id uint) (user.User, error) {
	q := `
	SELECT id, first_name, last_name, username, email, picture,
		created_at, updated_at
		FROM users WHERE id = $1;
	`
	row := ur.Data.DB.QueryRowContext(ctx, q, id)
	var u user.User
	err := row.Scan(&u.ID, &u.FirstName, &u.LastName, &u.Username, &u.Email,
		&u.Picture, &u.CreatedAt, &u.UpdatedAt)
	if err != nil {
		return user.User{}, err
	}
	return u, nil
}
func ( ur * UserRepository ) GetOne ( ctx context . Context , id uint ) ( user . User , error ) { q := `
	SELECT id, first_name, last_name, username, email, picture,
		created_at, updated_at
		FROM users WHERE id = $1;
	` row := ur . Data . DB . QueryRowContext ( ctx , q , id ) var u user . User err := row . Scan ( & u . ID , & u . FirstName , & u . LastName , & u . Username , & u . Email , & u . Picture , & u . CreatedAt , & u . UpdatedAt ) if err != nil { return user . User { } , err } return u , nil }
GetOne returns one user by id.
GetOne returns one user by id .