@@ -143,7 +143,7 @@ public function sendHtml(string $body, int $status = ResponseStatus::OkCode)
143143     * 
144144     * @throws \Exception 
145145     */ 
146-     public  function  sendJsonString (string  $ body , int  $ status  = 200 )
146+     public  function  sendJsonString (string  $ body , int  $ status  = ResponseStatus::OkCode )
147147    {
148148        $ config  = WaterPipeConfig::get ();
149149
@@ -162,7 +162,7 @@ public function sendJsonString(string $body, int $status = 200)
162162     * 
163163     * @throws \Exception 
164164     */ 
165-     public  function  sendJson (array  $ json , int  $ status  = 200 )
165+     public  function  sendJson (array  $ json , int  $ status  = ResponseStatus::OkCode )
166166    {
167167        $ this  ->sendJsonString (json_encode ($ json ), $ status );
168168    }
@@ -175,7 +175,7 @@ public function sendJson(array $json, int $status = 200)
175175     * 
176176     * @throws \Exception 
177177     */ 
178-     public  function  sendText (string  $ body , int  $ status  = 200 )
178+     public  function  sendText (string  $ body , int  $ status  = ResponseStatus::OkCode )
179179    {
180180        $ config  = WaterPipeConfig::get ();
181181
@@ -196,7 +196,7 @@ public function sendText(string $body, int $status = 200)
196196     * @throws \Exception 
197197     * @throws FileNotFoundException When the file was not found at the given path. 
198198     */ 
199-     public  function  sendFile (string  $ path , int  $ status  = 200 , string  $ mime  = null )
199+     public  function  sendFile (string  $ path , int  $ status  = ResponseStatus::OkCode , string  $ mime  = null )
200200    {
201201        $ config  = WaterPipeConfig::get ();
202202
0 commit comments