Affected Code: File: QuestFactory.sol line 100,131
Description:
transferOwnership
function is used to change Ownership from Owned.sol.
Use a 2 structure transferOwnership which is safer.
safeTransferOwnership
, use it is more secure due to 2-stage ownership transfer.
Recommendation: Use Ownable2Step.sol
Affected Code:
QuestFactory.sol line 2
RabbitHoleReceipt.sol line 2
RabbitHoleTickets.sol line 2
RecieptRenderer.sol line 2
Quest.sol line 2
IQuest.sol line 2
IQuestFactory.sol line 2
Description:
Pragma statements can be allowed to float when a contract is intended for consumption by other developers, as in the case with contracts in a library or EthPM package. Otherwise, the developer would need to manually update the pragma in order to compile locally.
https://swcregistry.io/docs/SWC-103
Recommendation: Ethereum Smart Contract Best Practices - Lock pragmas to specific compiler version. solidity-specific/locking-pragmas
Affected Code: RabbitHoleReceipt.sol #L158-160, #L192 QuestFactory.sol #L210, #L219 RabbitHoleTickets.sol #L83,#L102 Erc20Quest.sol #L74 Description:It is generally recommended that lines in the source code should not exceed 80-120 characters. Today’s screens are much larger, so in some cases it makes sense to expand that. The lines above should be split when they reach that length, as the files will most likely be on GitHub and GitHub always uses a scrollbar when the length is more than 164 characters.
See why-is-80-characters-the-standard-limit-for-code-width
Recommendation:
Multiline output parameters and return statements should follow the same style recommended for wrapping long lines found in the Maximum Line Length section.
https://docs.soliditylang.org/en/v0.8.17/style-guide.html#introduction
thisFunctionCallIsReallyLong(
longArgument1,
longArgument2,
longArgument3
);
Affected Code: Quest.sol#L38-L43 Erc20Quest.sol#L38-L39 Description: Events help non-contract tools to track changes, and events prevent users from being surprised by changes
Recommendation: Add Event-Emit.