Well, I placed it in the code and it had no effect whatsoever. Not sure what the issue is.
However, I have found a workaround and I am no longer in need of a quick solution.
Although a universal Entity/Swep User restrict code would be handy, I might just forget it.