Skip to content

Feathers trying to populate nonexistent columns "0" and "1" #206

Description

@madebyjono

I'm using postgresql v15.1 with a fresh installation of feathers
Followed the setup instructions to the T
In posting to my authentication 'users' endpoint:
http://localhost:3030/auth-management/verify-signup-short

I'm getting:

error: error: update "users" set "0" = $1, "1" = $2, "isVerified" = $3, "verifyToken" = $4, "verifyShortToken" = $5, "verifyExpires" = $6, "verifyChanges" = $7 where "users"."id" in ($8) - column "0" of relation "users" does not exist

When I manually create the columns "0" and "1" in the database, the rows are populated with a "{" and "}" for both of them.
Been dealing with it for a whole day and can't seem to figure it out!

My migration for users is

`export async function up(knex: Knex): Promise {
await knex.schema.createTable('users', (table) => {
table.increments('id');
table.integer('cellphone');
table.string('email').unique();
table.string('password');
table.string('verifyShortToken');
table.bigInteger('verifyExpires');
table.integer('resetAttempts');
table.integer('resetExpires');
table.string('resetShortToken')
table.string('resetToken');
table.string('verifyChanges');
table.boolean('isVerified');
table.string('verifyToken');
})
}

export async function down(knex: Knex): Promise {
await knex.schema.dropTable('users')
}`

Expected behavior

Successful verification of short token

Actual behavior

getting error
{ "name": "GeneralError", "message": "update \"users\" set \"0\" = $1, \"1\" = $2, \"isVerified\" = $3, \"verifyToken\" = $4, \"verifyShortToken\" = $5, \"verifyExpires\" = $6, \"verifyChanges\" = $7 where \"users\".\"id\" in ($8) - column \"0\" of relation \"users\" does not exist", "code": 500, "className": "general-error" }

NodeJS version:
18.15.0

Operating System:
MacOS

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions