aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTeddy Wing2016-09-10 21:44:58 -0400
committerTeddy Wing2016-09-10 21:44:58 -0400
commitbb2b602618da3df3d464984e97565cf5d25a37e2 (patch)
tree7a14b8a8f32c7543a3ae735ab21e5c65c26d8b80
parent8b3febb99846f99d5576e9386e456186f9c1d0f8 (diff)
downloadirssi-slack-profile-bb2b602618da3df3d464984e97565cf5d25a37e2.tar.bz2
swhois: Rename `$data` to `$username`
Because this name is so much clearer. I had used data because that's what's used in the Irssi command example.
-rw-r--r--slack-profile.pl10
1 files changed, 5 insertions, 5 deletions
diff --git a/slack-profile.pl b/slack-profile.pl
index 7c61fed..68039a6 100644
--- a/slack-profile.pl
+++ b/slack-profile.pl
@@ -61,7 +61,7 @@ sub find_user {
}
sub swhois {
- my ($data, $server, $window_item) = @_;
+ my ($username, $server, $window_item) = @_;
# if (!$server || !$server->{connected}) {
# Irssi::print("Not connected to server");
@@ -76,11 +76,11 @@ sub swhois {
}
}
- if ($data) {
- # If $data starts with @, strip it
- $data =~ s/^@//;
+ if ($username) {
+ # If $username starts with @, strip it
+ $username =~ s/^@//;
- if (my $user = find_user($data)) {
+ if (my $user = find_user($username)) {
my $bot = '';
if ($user->{'is_bot'}) {