error in knex query with null condition