diff --git a/lib/index.js b/lib/index.js
index <HASH>..<HASH> 100644
--- a/lib/index.js
+++ b/lib/index.js
@@ -12,10 +12,19 @@ fs.readdirSync(__dirname + '/middleware').forEach(function (filename) {
 });
 
 exports.defaults = function (app, overrides) {
+    if (typeof app.use !== 'function') {
+        overrides = app;
+        try {   // make sub-app, in likeliest framework(s)
+            app = require('express')();
+        } catch (e) {
+            app = require('connect')();
+        }
+    }
     overrides = overrides || {csp: false};
     middleware.forEach(function _eachMiddleware(m) {
         if (overrides[m] !== false) {
             app.use(require('./middleware/' + m)());
         }
     });
+    return app;
 };
Support helmet.defaults() as middleware, fixes #<I>

Here's a simple way to support both the old and more conventional middleware-like usage of `helmet.defaults()`.



NOTE: there's one caveat in that the user *must* be using (i.e. have installed) either 'express' or 'connect' themselves but that seemed a reasonable enough assumption, eh?