Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: missing virtual keyword #452

Merged
merged 6 commits into from
Aug 29, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/contracts-ethers/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@aragon/osx-ethers",
"version": "1.3.0-rc0.2",
"version": "1.3.1-rc0",
"description": "The Aragon OSx contract definitions for ethers.js",
"main": "dist/bundle-cjs.js",
"module": "dist/bundle-esm.js",
Expand Down
10 changes: 10 additions & 0 deletions packages/contracts/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,16 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## v1.3.1-rc0

### Added

### Changed

- Added missing `virtual` keyword to `PermissionCondition` and `PermissionConditionUpgradeable`.

### Removed

## v1.3.0-rc0

### Added
Expand Down
2 changes: 1 addition & 1 deletion packages/contracts/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@aragon/osx-artifacts",
"version": "1.3.0-rc0.2",
"version": "1.3.1-rc0",
"description": "The Aragon OSx Solidity contracts",
"main": "dist/bundle-cjs.js",
"module": "dist/bundle-esm.js",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,19 @@ pragma solidity ^0.8.8;

/// @title IPermissionCondition
/// @author Aragon Association - 2021-2023
/// @notice This interface can be implemented to support more customary permissions depending on on- or off-chain state, e.g., by querying token ownershop or a secondary condition, respectively.
/// @notice An interface to be implemented to support custom permission logic.
/// @dev To attach a condition to a permission, the `grantWithCondition` function must be used and refer to the implementing contract's address with the `condition` argument.
interface IPermissionCondition {
/// @notice This method is used to check if a call is permitted.
/// @notice Checks if a call is permitted.
/// @param _where The address of the target contract.
/// @param _who The address (EOA or contract) for which the permissions are checked.
/// @param _permissionId The permission identifier.
/// @param _data Optional data passed to the `PermissionCondition` implementation.
/// @return allowed Returns true if the call is permitted.
/// @return isPermitted Returns true if the call is permitted.
function isGranted(
address _where,
address _who,
bytes32 _permissionId,
bytes calldata _data
) external view returns (bool allowed);
) external view returns (bool isPermitted);
}
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ abstract contract PermissionCondition is ERC165, IPermissionCondition {
/// @notice Checks if an interface is supported by this or its parent contract.
/// @param _interfaceId The ID of the interface.
/// @return Returns `true` if the interface is supported.
function supportsInterface(bytes4 _interfaceId) public view override returns (bool) {
function supportsInterface(bytes4 _interfaceId) public view virtual override returns (bool) {
return
_interfaceId == type(IPermissionCondition).interfaceId ||
super.supportsInterface(_interfaceId);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ abstract contract PermissionConditionUpgradeable is ERC165Upgradeable, IPermissi
/// @notice Checks if an interface is supported by this or its parent contract.
/// @param _interfaceId The ID of the interface.
/// @return Returns `true` if the interface is supported.
function supportsInterface(bytes4 _interfaceId) public view override returns (bool) {
function supportsInterface(bytes4 _interfaceId) public view virtual override returns (bool) {
return
_interfaceId == type(IPermissionCondition).interfaceId ||
super.supportsInterface(_interfaceId);
Expand Down
2 changes: 1 addition & 1 deletion packages/contracts/src/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@aragon/osx",
"version": "1.3.0-rc0.2",
"version": "1.3.1-rc0",
"description": "The Aragon OSx Solidity contracts",
"publishConfig": {
"access": "public"
Expand Down
Loading