Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

cetera

Package Overview
Dependencies
Maintainers
1
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cetera - npm Package Compare versions

Comparing version 0.0.7 to 0.0.8

41

lib/cache/production_cache.js

@@ -14,3 +14,3 @@ // Generated by CoffeeScript 1.6.3

ProductionCache.prototype.route = function(conf) {
var app, name, route, script, scripts, src, _i, _len, _results;
var app, name, script, scripts, src, _i, _len, _results;
app = conf.app;

@@ -23,22 +23,25 @@ scripts = conf.scripts;

script = scripts[_i];
route = "/" + name + "/" + script;
_results.push(app.get(route, function(req, res) {
var file, match;
res.header({
'Content-Type': 'text/javascript'
});
if (cache[route] != null) {
return res.send(cache[route]);
}
match = req.path.match(new RegExp("^\/" + name + "\/(.*)"));
file = path.join(src, match[1]);
return fs.readFile(file, function(err, data) {
if (err == null) {
cache[route] = data;
return res.send(data);
_results.push((function(script) {
var route;
route = "/" + name + "/" + script;
return app.get(route, function(req, res) {
var file, match;
res.header({
'Content-Type': 'text/javascript'
});
if (cache[route] != null) {
return res.send(cache[route]);
}
res.statusCode = 404;
return res.send();
match = req.path.match(new RegExp("^\/" + name + "\/(.*)"));
file = path.join(src, match[1]);
return fs.readFile(file, function(err, data) {
if (err == null) {
cache[route] = data;
return res.send(data);
}
res.statusCode = 404;
return res.send();
});
});
}));
})(script));
}

@@ -45,0 +48,0 @@ return _results;

{
"name": "cetera",
"description": "effortlessness, requirejs, packager, modules",
"version": "0.0.7",
"version": "0.0.8",
"author": "nomilous <nomilous@gmail.com",

@@ -6,0 +6,0 @@ "contributors": [

@@ -6,3 +6,3 @@ cetera

### version 0.0.7 (high alpha)
### version 0.0.8 (high alpha)

@@ -9,0 +9,0 @@

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc