Changeset d748296 for lib/BarnOwl/Module/Twitter.pm
- Timestamp:
- Jul 21, 2009, 10:06:32 PM (15 years ago)
- Branches:
- master, release-1.10, release-1.7, release-1.8, release-1.9
- Children:
- 82fd1e6
- Parents:
- 7430aa4
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
lib/BarnOwl/Module/Twitter.pm
r159aaad rd748296 23 23 use BarnOwl::Module::Twitter::Handle; 24 24 25 our @twitter_handles ;26 our $default_handle ;25 our @twitter_handles = (); 26 our $default_handle = undef; 27 27 my $user = BarnOwl::zephyr_getsender(); 28 28 my ($class) = ($user =~ /(^[^@]+)/); … … 114 114 } 115 115 116 my $twitter_handle = BarnOwl::Module::Twitter::Handle->new($cfg, %$twitter_args); 117 push @twitter_handles, $twitter_handle; 118 $default_handle = $twitter_handle if (!defined $twitter_handle && exists $cfg->{default_sender} && $cfg->{default_sender}); 116 eval { 117 my $twitter_handle = BarnOwl::Module::Twitter::Handle->new($cfg, %$twitter_args); 118 push @twitter_handles, $twitter_handle; 119 $default_handle = $twitter_handle if (!defined $twitter_handle && exists $cfg->{default_sender} && $cfg->{default_sender}); 120 }; 119 121 } 120 122 … … 140 142 141 143 sub poll_messages { 144 return unless @twitter_handles; 145 142 146 my $handle = $twitter_handles[$next_service_to_poll]; 143 147 $next_service_to_poll = ($next_service_to_poll + 1) % scalar(@twitter_handles);
Note: See TracChangeset
for help on using the changeset viewer.