slight difference between video and code. why? (virtual & override)
innovinitylabs opened this issue · comments
function store(uint256 _favoriteNumber) public virtual override {
- is in this git
but in tutorial, it was just
function store(uint256 _favoriteNumber) public override {
why
The virtual
keyword is in the video too... I just moved too quick when adding it :/
You need virtual
to tell our ExtraStorage
contract that it is allowed to override the function. Without the virtual
keyword, we can't override the function.