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

bitagora-booth

Package Overview
Dependencies
Maintainers
1
Versions
178
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bitagora-booth - npm Package Compare versions

Comparing version 1.0.153 to 1.0.154

14

lib/functions.js

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

if (Boolean(opt) && Boolean(opt['filter'])) url = url + "?address="+opt['filter']
console.log("Requesting state at address");
console.log(url);
request.get({ url: url },

@@ -194,3 +192,2 @@ (err, response) => {

} else if (type == 'polls') {
console.log("In polls");
let polls = [];

@@ -279,20 +276,11 @@ for (var i=0; i<json.data.length; i++) {

function getBallot(ballot, poll, voterPrivkeyHex) {
console.log("In get ballot");
console.log(ballot);
console.log(poll);
console.log("Poll is open? "+poll.open.toString());
try {
if (poll.open) {
console.log("Returning unencrypted ballot");
return ballot;
} else {
console.log("Encrypting ballot");
if (Object.keys(poll.values).indexOf(ballot) == -1 ) throw 'Ballot not valid';
let encrypted = encryptBallot(ballot, poll.certkey, voterPrivkeyHex);
consoole.log("Encrypted is");
console.log(encrypted);
return encrypted;
}
} catch(e) {
console.log("Error returning undefined");
console.log(e);

@@ -319,4 +307,2 @@ return undefined;

if (type != 'polls' && type != 'ballots' && !Boolean(address)) throw 'No address';
console.log(address);
console.log(opt);
if (process.env.API_URL !== undefined) {

@@ -323,0 +309,0 @@ requestStateFromAPI(process.env.API_URL, address, type, opt).then((result) => {

2

package.json
{
"name": "bitagora-booth",
"version": "1.0.153",
"version": "1.0.154",
"license": "Apache-2.0",

@@ -5,0 +5,0 @@ "author": "Ignasi Ribó, 2018",

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