If I have a function that just sets a value like this:
function setBytes(
bytes32 _value
) public {
testBytes = _value;
}
Should this kind of functions return a value or should the function remain without a return if the function is called from another contract? In some code examples, I have seen that this kind of functions returns true. Like this:
function setBytes(
bytes32 _value
) public returns(bool success) {
testBytes = _value;
return true;
}
What is the best practice in such cases and what is the purpose of returning true?