Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trial
Zachary Rolland
16,465 PointsError on server.coffee : express.createServer is deprecated?
When I run the coffee server.coffee as I am doing the CodeRacer tutorial i get this:
Warning: express.createServer() is deprecated, express applications no longer inherit from http.Server, please use:
var express = require("express"); var app = express();
How do I fix it? Thanks
2 Answers
Zachary Rolland
16,465 Pointsmust have something to do with express.js 3.0...
Richard Terrell
3,728 PointsYou probably already found this but here it is for other people.
Replace the whole "createServer" line with:
app = express()