19 lines
390 B
Solidity
19 lines
390 B
Solidity
pragma solidity ^0.4.8;
|
|
|
|
|
|
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);
|
|
}
|
|
}
|