Skip to content
This repository has been archived by the owner on Jun 29, 2020. It is now read-only.

Commit

Permalink
Merge ee929a3 into 75bf588
Browse files Browse the repository at this point in the history
  • Loading branch information
unjapones committed Sep 17, 2018
2 parents 75bf588 + ee929a3 commit 70bba0e
Show file tree
Hide file tree
Showing 5 changed files with 2,069 additions and 2,043 deletions.
6 changes: 6 additions & 0 deletions blockchain/.solhint.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"extends": "default",
"rules": {
"indent": ["warn", 2]
}
}
11 changes: 6 additions & 5 deletions blockchain/contracts/Migrations.sol
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
pragma solidity ^0.4.17;


contract Migrations {
address public owner;
uint public last_completed_migration;
uint public lastCompleteMigration;

modifier restricted() {
if (msg.sender == owner) _;
Expand All @@ -13,11 +14,11 @@ contract Migrations {
}

function setCompleted(uint completed) public restricted {
last_completed_migration = completed;
lastCompleteMigration = completed;
}

function upgrade(address new_address) public restricted {
Migrations upgraded = Migrations(new_address);
upgraded.setCompleted(last_completed_migration);
function upgrade(address newAddress) public restricted {
Migrations upgraded = Migrations(newAddress);
upgraded.setCompleted(lastCompleteMigration);
}
}
6 changes: 3 additions & 3 deletions blockchain/contracts/PoBA.sol
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,9 @@ contract PoBA {
function signerIsValid(bytes32 data, uint8 v, bytes32 r, bytes32 s)
public constant returns (bool)
{
bytes memory prefix = "\x19Ethereum Signed Message:\n32";
bytes32 prefixed = keccak256(abi.encodePacked(prefix, data));
return (ecrecover(prefixed, v, r, s) == signer);
bytes memory prefix = "\x19Ethereum Signed Message:\n32";
bytes32 prefixed = keccak256(abi.encodePacked(prefix, data));
return (ecrecover(prefixed, v, r, s) == signer);
}

function userExists(address wallet)
Expand Down

0 comments on commit 70bba0e

Please sign in to comment.