More tab removal.

This commit is contained in:
Elijah Perrault committed 2011-03-21 14:18:57 -06:00
1 parent 153084f808
commit ea775d4c98
5 files changed
+206 -206

No files matched your search

+21 -21
View File
@@ -15,34 +15,34 @@ hook_add('on_namesreply', 'state.irc.names', sub {
if (defined $chanusers{$svr}{$chan}) { delete $chanusers{$svr}{$chan} }
# Iterate through each user.
for (1..$#data) {
my $fi = 0;
my $fi = 0;
PFITER: foreach my $spfx (keys %{ $Proto::IRC::csprefix{$svr} }) {
# Check if the user has status in the channel.
if (substr($data[$_], 0, 1) eq $Proto::IRC::csprefix{$svr}{$spfx}) {
# He/she does. Lets set that.
if (defined $chanusers{$svr}{$chan}{lc $data[$_]}) {
# If the user has multiple statuses.
$chanusers{$svr}{$chan}{lc substr $data[$_], 1} = $chanusers{$svr}{$chan}{lc $data[$_]}.$spfx;
# Check if the user has status in the channel.
if (substr($data[$_], 0, 1) eq $Proto::IRC::csprefix{$svr}{$spfx}) {
# He/she does. Lets set that.
if (defined $chanusers{$svr}{$chan}{lc $data[$_]}) {
# If the user has multiple statuses.
$chanusers{$svr}{$chan}{lc substr $data[$_], 1} = $chanusers{$svr}{$chan}{lc $data[$_]}.$spfx;
delete $chanusers{$svr}{$chan}{lc $data[$_]};
}
else {
# Or not.
$chanusers{$svr}{$chan}{lc substr $data[$_], 1} = $spfx;
}
$fi = 1;
}
else {
# Or not.
$chanusers{$svr}{$chan}{lc substr $data[$_], 1} = $spfx;
}
$fi = 1;
$data[$_] = substr $data[$_], 1;
}
}
}
}
# Check if there's still a prefix.
foreach my $spfx (keys %{$Proto::IRC::csprefix{$svr}}) {
if (substr($data[$_], 0, 1) eq $Proto::IRC::csprefix{$svr}{$spfx}) { goto 'PFITER' }
}
# They had status, so go to the next user.
next if $fi;
# They didn't, set them as a normal user.
if (!defined $chanusers{$svr}{$chan}{lc $data[$_]}) {
$chanusers{$svr}{$chan}{lc $data[$_]} = 1;
}
# They had status, so go to the next user.
next if $fi;
# They didn't, set them as a normal user.
if (!defined $chanusers{$svr}{$chan}{lc $data[$_]}) {
$chanusers{$svr}{$chan}{lc $data[$_]} = 1;
}
}
return 1;