{
    "Function": "setFollowModule",
    "File": "contracts/libraries/PublishingLogic.sol",
    "Parent Contracts": [],
    "High-Level Calls": [],
    "Internal Calls": [
        "_initFollowModule"
    ],
    "Library Calls": [],
    "Low-Level Calls": [],
    "Code": "function setFollowModule(\n        uint256 profileId,\n        address followModule,\n        bytes calldata followModuleData,\n        DataTypes.ProfileStruct storage _profile,\n        mapping(address => bool) storage _followModuleWhitelisted\n    ) external {\n        address prevFollowModule = _profile.followModule;\n        if (followModule != prevFollowModule) {\n            _profile.followModule = followModule;\n        }\n\n        bytes memory followModuleReturnData = _initFollowModule(\n            profileId,\n            followModule,\n            followModuleData,\n            _followModuleWhitelisted\n        );\n        emit Events.FollowModuleSet(\n            profileId,\n            followModule,\n            followModuleReturnData,\n            block.timestamp\n        );\n    }"
}