fCraft.PlayerInfo.ProcessUnban C# (CSharp) Method

ProcessUnban() private method

private ProcessUnban ( [ unbannedByName, [ unbanReason ) : bool
unbannedByName [
unbanReason [
return bool
        internal bool ProcessUnban( [NotNull] string unbannedByName, [CanBeNull] string unbanReason )
        {
            if ( unbannedByName == null )
                throw new ArgumentNullException( "unbannedByName" );
            lock ( actionLock ) {
                if ( IsBanned ) {
                    BanStatus = BanStatus.NotBanned;
                    UnbannedBy = unbannedByName;
                    UnbanDate = DateTime.UtcNow;
                    UnbanReason = unbanReason;
                    LastModified = DateTime.UtcNow;
                    return true;
                } else {
                    return false;
                }
            }
        }