gx0r/connect-session-knex

Doc and example out of sync

Closed this issue · 2 comments

Both in readme and https://github.com/llambda/connect-session-knex/blob/master/example-postgres.js#L19 you ask to use field called knex when actually you expect Store

gx0r commented

const KnexSessionStore = require('connect-session-knex')(session);
session here is the express-session module

const store = new KnexSessionStore({
knex: knex,
tablename: 'sessions' // optional. Defaults to 'sessions'
});

knex here is the knex instance.

Oh. Got it. Thanks. It wasn't so clear. Maybe just add to README actual use example rather than just options.