mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
22 lines
544 B
Solidity
22 lines
544 B
Solidity
pragma solidity ^0.4.11;
|
|
|
|
|
|
import '../ownership/Ownable.sol';
|
|
|
|
/**
|
|
* @title Migrations
|
|
* @dev This is a truffle contract, needed for truffle integration, not meant for use by Zeppelin users.
|
|
*/
|
|
contract Migrations is Ownable {
|
|
uint256 public lastCompletedMigration;
|
|
|
|
function setCompleted(uint256 completed) public onlyOwner {
|
|
lastCompletedMigration = completed;
|
|
}
|
|
|
|
function upgrade(address newAddress) public onlyOwner {
|
|
Migrations upgraded = Migrations(newAddress);
|
|
upgraded.setCompleted(lastCompletedMigration);
|
|
}
|
|
}
|