freedom-for-node
Advanced tools
Comparing version 0.0.8 to 0.1.0
@@ -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 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
31345
619
7
+ Addedes5-shim@^3.4.0
+ Addedes5-shim@3.4.0(transitive)
+ Addedfreedom@0.5.7(transitive)
- Removedfreedom@0.4.12(transitive)
Updatedfreedom@~0.5.0