mirror of
https://github.com/lens-protocol/core.git
synced 2026-01-10 14:48:15 -05:00
misc: Action module enabled getter added
This commit is contained in:
@@ -540,6 +540,15 @@ contract LensHub is
|
||||
return StorageLib.getPublicationMemory(profileId, pubId);
|
||||
}
|
||||
|
||||
/// @inheritdoc ILensProtocol
|
||||
function isActionModuleEnabledInPublication(
|
||||
uint256 profileId,
|
||||
uint256 pubId,
|
||||
address module
|
||||
) external view returns (bool) {
|
||||
return StorageLib.getPublication(profileId, pubId).actionModuleEnabled[module];
|
||||
}
|
||||
|
||||
/// @inheritdoc ILensProtocol
|
||||
function getPublicationType(
|
||||
uint256 profileId,
|
||||
|
||||
@@ -450,4 +450,19 @@ interface ILensProtocol {
|
||||
* @return PublicationType The publication type of the queried publication.
|
||||
*/
|
||||
function getPublicationType(uint256 profileId, uint256 pubId) external view returns (Types.PublicationType);
|
||||
|
||||
/**
|
||||
* @notice Returns wether a given Action Module is enabled for a given publication.
|
||||
*
|
||||
* @param profileId The token ID of the profile that published the publication to query.
|
||||
* @param pubId The publication ID of the publication to query.
|
||||
* @param module The address of the Action Module to query.
|
||||
*
|
||||
* @return bool True if the Action Module is enabled for the queried publication, false if not.
|
||||
*/
|
||||
function isActionModuleEnabledInPublication(
|
||||
uint256 profileId,
|
||||
uint256 pubId,
|
||||
address module
|
||||
) external view returns (bool);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user