```\nuint holderBalance = SkaleToken(contractManager.getContract("SkaleToken")).balanceOf(holder);\nuint lockedToDelegate = tokenState.getLockedCount(holder) - tokenState.getPurchasedAmount(holder);\nrequire(holderBalance >= amount + lockedToDelegate, "Delegator hasn't enough tokens to delegate");\n```\n