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

mvcfun

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mvcfun - npm Package Compare versions

Comparing version 0.4.3 to 0.4.4-r1

22

lib/controller/Base.js

@@ -72,2 +72,12 @@ /**

/**
* The instance of the server which is running this controller. This will
* be injected by the server itself on registering a controller.
* See http.Server.prototype.addController for details.
*
* @protected
* @var {http.Server}
*/
this._server = null;
/**
* The current language of the controller. Has to be one of the iso strings

@@ -220,2 +230,14 @@ * 'en', 'de', ... This will be added to any response header at run:

/**
* The server.
*
* @member {http.Server} server
* @readonly
*/
nepp.createGS(module.exports.prototype, 'server',
function getServer() {
return this._server
}
);
/**
* The session object.

@@ -222,0 +244,0 @@ *

1

lib/http/Server.js

@@ -311,2 +311,3 @@ /**

module.exports.prototype.addController = function(controller) {
controller._server = this;
this.requestManager.requestController.addController(controller);

@@ -313,0 +314,0 @@ };

@@ -24,2 +24,4 @@ /**

* In controllers, use the log methods to emit this event.
* 'error' Event:
* Errors thrown will be caught an emitted using this event.
*

@@ -26,0 +28,0 @@ * @param {Object} respManagers Response manangers.

@@ -151,2 +151,18 @@ /**

/**
* Write bad request to the response object.
*
* @param {http.ServerResponse} resp Reponse Object.
* @param {String} language The language of the content.
*/
module.exports.prototype.writeBadRequest = function(resp, err, language) {
VC.instance_of(resp, 'resp', http.ServerResponse);
resp.writeHead(
HTTPStatusCodes.BAD_REQUEST,
this._createHeader(language)
);
resp.end(this._prepareErrorMessage('Bad request'));
};
/**
* Writes unauthorized to the response object.

@@ -153,0 +169,0 @@ *

2

package.json
{
"name": "mvcfun",
"version": "0.4.3",
"version": "0.4.4r1",
"description": "MVC based web server framework",

@@ -5,0 +5,0 @@ "main": "index.js",

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