From ed4a849ff499c046041514fe6e31d2bd3ef6f0b2 Mon Sep 17 00:00:00 2001 From: Beau Collins Date: Thu, 20 Dec 2012 09:31:51 -0800 Subject: [PATCH] Make sure we only emit 'end' once --- lib/Phluid/Request.php | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/Phluid/Request.php b/lib/Phluid/Request.php index e751c11..1a46896 100644 --- a/lib/Phluid/Request.php +++ b/lib/Phluid/Request.php @@ -25,6 +25,7 @@ function __construct( HttpRequest $request ){ $request->on( 'end', function(){ if ( !$this->ended ) { + $this->ended = true; $this->emit( 'end' ); } });