Skip to content

BodyParser and express-session out of date in samples #3

@cehager

Description

@cehager

Hi Brad,
I really liked your book "Node.js, MongoDb, Angularjs Web Development". Only issue I had with your GitHub files is that bodyParser has been depreciated and the new info isn't in your samples. I think this happened about the time you published the book.

I changed samples as needed to be:
app.use(bodyParser.urlencoded({ extended: true }));
app.use(cookieParser());

Also express-session seems to need resave and saveUninitialized to be set to true/false (no longer defaults)

After the above changes ALL your samples ran great! (and that's a big deal). Your book is one that I will keep close at hand. Thanks much!

I would offer the changes as a pull request but I have mangled your samples trying out various "what happens if I do this" experiments.

Cheers
Charlie

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions