rearrange folders
This commit is contained in:
18
contracts/lifecycle/Migrations.sol
Normal file
18
contracts/lifecycle/Migrations.sol
Normal file
@ -0,0 +1,18 @@
|
||||
pragma solidity ^0.4.4;
|
||||
|
||||
|
||||
import '../ownership/Ownable.sol';
|
||||
|
||||
|
||||
contract Migrations is Ownable {
|
||||
uint public lastCompletedMigration;
|
||||
|
||||
function setCompleted(uint completed) onlyOwner {
|
||||
lastCompletedMigration = completed;
|
||||
}
|
||||
|
||||
function upgrade(address newAddress) onlyOwner {
|
||||
Migrations upgraded = Migrations(newAddress);
|
||||
upgraded.setCompleted(lastCompletedMigration);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user