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

freedom-for-node

Package Overview
Dependencies
Maintainers
1
Versions
38
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

freedom-for-node - npm Package Compare versions

Comparing version 0.0.8 to 0.1.0

6

index.js

@@ -11,7 +11,9 @@ /*jslint indent:2,white:true,sloppy:true,node:true */

var fileInfo = require('freedom'),
glob = require('glob');
glob = require('glob'),
freedomPrefix = require.resolve('freedom').substr(0,
require.resolve('freedom').lastIndexOf('freedom') + 8);
fileInfo.FILES.srcCore.concat(
fileInfo.FILES.srcPlatform).forEach(function(dir) {
glob.sync(fileInfo.baseName + '/' + dir).forEach(function(file) {
glob.sync(freedomPrefix + '/' + dir).forEach(function(file) {
require(file);

@@ -18,0 +20,0 @@ });

{
"name": "freedom-for-node",
"description": "Embracing a distributed web",
"version": "0.0.8",
"version": "0.1.0",
"homepage": "http://freedomjs.org",

@@ -26,6 +26,7 @@ "bugs": {

"dependencies": {
"freedom": "~0.4.12",
"es5-shim": "^3.4.0",
"es6-promise": "~1.0.0",
"json-store": "0.0.1",
"glob": "~4.0.2"
"freedom": "~0.5.0",
"glob": "~4.0.2",
"json-store": "0.0.1"
},

@@ -36,4 +37,4 @@ "optionalDependencies": {

"peerDependencies": {
"freedom": "~0.4.12"
"freedom": "0.5.0"
}
}

@@ -42,4 +42,4 @@ /*globals require,fdom:true, console */

callback(undefined, {
errcode: "SOCKET_CLOSED",
message: "Cannot Write on non-connected Socket"
"errcode": "NOT_CONNECTED",
"message": "Cannot Write on Closed Socket"
});

@@ -79,3 +79,6 @@ return;

console.warn('Attempting to connect on in use socket');
return cb(false);
return cb(undefined, {
"errcode": "ALREADY_CONNECTED",
"message": "Cannot Connect Existing Socket"
});
}

@@ -116,3 +119,3 @@

this.callback(undefined, {
errcode: "SOCKET_CLOSED",
"errcode": "CONNECTION_FAILED",
message: "Socket Error: " + error.message

@@ -139,4 +142,4 @@ });

this.dispatchEvent('onDisconnect', {
errcode: "SOCKET_CLOSED",
message: "Socket Closed"
errcode: 'CONNECTION_CLOSED',
message: 'Connection closed gracefully'
});

@@ -189,4 +192,7 @@ delete this.connection;

if (this.state !== TcpSocket_node.state.NEW) {
console.warn('Attempting to listen on in use socket');
return callback(false);
callback(undefined, {
errcode: "ALREADY_CONNECTED",
message: "Cannot Listen on existing socket."
});
return;
}

@@ -193,0 +199,0 @@

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