For me, I consider that optional, and only needed in certain cases. But in case you need it, functions can return a value. that applies for functions in hooks too. in case with booleans you can just do
return false or
return true
Here's an example of use
View attachment 176848
You should
check out in the wiki (Hooks) to see what's the behavior of returning true or false. Anyways you should test with both to see which one works for you.