about summary refs log tree commit homepage
path: root/lib/PublicInbox/DS.pm
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2019-06-24 02:52:11 +0000
committerEric Wong <e@80x24.org>2019-06-24 05:26:26 +0000
commitf6c9b3da9cf87cfbde7b95772de6b337ba46ef68 (patch)
tree0b2a425caa29fd77b5d46841a8e5dac9631fd1c2 /lib/PublicInbox/DS.pm
parentb4aae3e011e24a9aacbd6d84c0e0aa610144bb76 (diff)
downloadpublic-inbox-f6c9b3da9cf87cfbde7b95772de6b337ba46ef68.tar.gz
ds: remove support for DS->write(undef)
We call ->flush_write directly, now; so we can eliminate a
needless check.
Diffstat (limited to 'lib/PublicInbox/DS.pm')
-rw-r--r--lib/PublicInbox/DS.pm3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/PublicInbox/DS.pm b/lib/PublicInbox/DS.pm
index 8fc49eee..ba8bd95f 100644
--- a/lib/PublicInbox/DS.pm
+++ b/lib/PublicInbox/DS.pm
@@ -518,14 +518,13 @@ sub flush_write ($) {
 =head2 C<< $obj->write( $data ) >>
 
 Write the specified data to the underlying handle.  I<data> may be scalar,
-scalar ref, code ref (to run when there), or undef just to kick-start.
+scalar ref, code ref (to run when there).
 Returns 1 if writes all went through, or 0 if there are writes in queue. If
 it returns 1, caller should stop waiting for 'writable' events)
 
 =cut
 sub write {
     my ($self, $data) = @_;
-    return flush_write($self) unless defined $data;
 
     # nobody should be writing to closed sockets, but caller code can
     # do two writes within an event, have the first fail and