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

nodecommons-express

Package Overview
Dependencies
Maintainers
1
Versions
32
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nodecommons-express - npm Package Compare versions

Comparing version 1.4.4 to 1.4.5

4

dist/helpers/commons-express.d.ts

@@ -16,4 +16,4 @@ import * as express from 'express';

static isNpm1985TimestampFile(file: string): boolean;
static setLastModifiedNow(res: express.Response): void;
static autoNpm1985TimestampFile(file: string, res: express.Response): void;
static setLastModified(res: express.Response, timestamp: Date): void;
static autoNpm1985TimestampFile(file: string, res: express.Response, timestamp: Date): void;
}

@@ -107,10 +107,10 @@ "use strict";

// See note 2 at top of CommonsExpressServer
static setLastModifiedNow(res) {
res.setHeader('Last-Modified', new Date().toUTCString());
static setLastModified(res, timestamp) {
res.setHeader('Last-Modified', timestamp.toUTCString());
}
// See note 2 at top of CommonsExpressServer
static autoNpm1985TimestampFile(file, res) {
static autoNpm1985TimestampFile(file, res, timestamp) {
if (!CommonsExpress.isNpm1985TimestampFile(file))
return;
CommonsExpress.setLastModifiedNow(res);
CommonsExpress.setLastModified(res, timestamp);
}

@@ -117,0 +117,0 @@ }

@@ -14,2 +14,3 @@ /// <reference types="node" />

private usingNpmResources;
private nodeStartTime;
constructor(ex: express.Express, server: http.Server | https.Server, port: number);

@@ -16,0 +17,0 @@ setUsingNpmResources(state?: boolean): void;

@@ -50,2 +50,3 @@ "use strict";

this.usingNpmResources = false;
this.nodeStartTime = new Date();
}

@@ -136,3 +137,3 @@ static nginxProxyPath(p) {

if (this.usingNpmResources) {
commons_express_1.CommonsExpress.autoNpm1985TimestampFile(p, res);
commons_express_1.CommonsExpress.autoNpm1985TimestampFile(p, res, this.nodeStartTime);
}

@@ -147,3 +148,3 @@ }

if (this.usingNpmResources) {
commons_express_1.CommonsExpress.autoNpm1985TimestampFile(p, res);
commons_express_1.CommonsExpress.autoNpm1985TimestampFile(p, res, new Date());
}

@@ -158,3 +159,3 @@ }

if (this.usingNpmResources) {
commons_express_1.CommonsExpress.autoNpm1985TimestampFile(p, res);
commons_express_1.CommonsExpress.autoNpm1985TimestampFile(p, res, this.nodeStartTime);
}

@@ -179,3 +180,3 @@ }

// See note 2 at top
commons_express_1.CommonsExpress.setLastModifiedNow(res);
commons_express_1.CommonsExpress.setLastModified(res, this.nodeStartTime);
res.sendFile(path.join(absolute, '/index.html'));

@@ -182,0 +183,0 @@ });

{
"name": "nodecommons-express",
"version": "1.4.4",
"version": "1.4.5",
"description": "",

@@ -5,0 +5,0 @@ "scripts": {

Sorry, the diff of this file is not supported yet

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