title: Expressjs not loading stylesheets on heroku, giving 500 error
body: <p>I'm running an Expressjs installation on heroku, and it's not loading the stylesheets.</p>
  
  <p>I hit ctrl+u and then click on the stylesheet link, and get this error:</p>
  
  <pre><code>TypeError: Object #&lt;SendStream&gt; has no method 'on'
      at Object.static [as handle] (/app/node_modules/express/node_modules/connect/lib/middleware/static.js:75:8)
      at next (/app/node_modules/express/node_modules/connect/lib/proto.js:190:15)
  </code></pre>
  
  <p>When I go to the url '/stylesheets/style.css' I get this error:</p>
  
  <pre><code>Express
  500 TypeError: Object #&lt;SendStream&gt; has no method 'on'
  
      at Object.static [as handle] (/app/node_modules/express/node_modules/connect/lib/middleware/static.js:75:8)
      at next (/app/node_modules/express/node_modules/connect/lib/proto.js:190:15)
      at /app/node_modules/stylus/lib/middleware.js:174:46
      at /app/node_modules/stylus/lib/middleware.js:208:20
  </code></pre>
  
  <p>Everything works fine locally.</p>
  
  <p>here is the package.json</p>
  
  <pre><code>  {
      "name": "app-name",
        "version": "0.0.1",
        "private": true,
        "scripts": {
        "start": "node app"
       },
       "dependencies": {
         "express": "3.0.0rc1",
         "jade": "*",
         "stylus": "*"
       }
     }
  </code></pre>
  
  <p>The app.js:</p>
  
  <pre><code>/**
   * Module dependencies.
   */
   var express = require('express')
    , routes = require('./routes')
    , http = require('http')
    , path = require('path');
  
  var app = express();
  
  app.configure(function(){
    app.set('port', process.env.PORT || 3000);
    app.set('views', __dirname + '/views');
    app.set('view engine', 'jade');
    app.use(express.favicon());
    app.use(express.logger('dev'));
    app.use(express.bodyParser());
    app.use(express.methodOverride());
    app.use(app.router);
    app.use(require('stylus').middleware(__dirname + '/public'));
    app.use(express.static(path.join(__dirname, 'public')));
  });
  
  app.configure('development', function(){
    app.use(express.errorHandler());
  });
  
  app.get('/', routes.index);
  app.get('/about', routes.about);
  
  http.createServer(app).listen(app.get('port'), function(){
    console.log("Express server listening on port " + app.get('port'));
  });
  </code></pre>
  
  <p>The Procfile:</p>
  
  <pre><code>web: node app.js
  </code></pre>
  
  <p>If I keep refreshing, it crashes the app.</p>