I saw the source code and the default value and the return if it not found the script, shouldn't be true? Actually is false, but if it don't find it return false, and the canDelete() return false without verify the other conditions...

And how can I make de restriction, I don't understand what you say...
It's worng this: