@@ -177,9 +177,9 @@ public function handleTestChunk()
177177 {
178178 $ identifier = $ this ->resumableParam ($ this ->resumableOption ['identifier ' ]);
179179 $ filename = $ this ->resumableParam ($ this ->resumableOption ['filename ' ]);
180- $ chunkNumber = $ this ->resumableParam ($ this ->resumableOption ['chunkNumber ' ]);
181- $ chunkSize = $ this ->resumableParam ($ this ->resumableOption ['chunkSize ' ]);
182- $ totalChunks = $ this ->resumableParam ($ this ->resumableOption ['totalChunks ' ]);
180+ $ chunkNumber = ( int ) $ this ->resumableParam ($ this ->resumableOption ['chunkNumber ' ]);
181+ $ chunkSize = ( int ) $ this ->resumableParam ($ this ->resumableOption ['chunkSize ' ]);
182+ $ totalChunks = ( int ) $ this ->resumableParam ($ this ->resumableOption ['totalChunks ' ]);
183183
184184 if (!$ this ->isChunkUploaded ($ identifier , $ filename , $ chunkNumber )) {
185185 return $ this ->response ->header (204 );
@@ -199,9 +199,9 @@ public function handleChunk()
199199 $ file = $ this ->request ->file ();
200200 $ identifier = $ this ->resumableParam ($ this ->resumableOption ['identifier ' ]);
201201 $ filename = $ this ->resumableParam ($ this ->resumableOption ['filename ' ]);
202- $ chunkNumber = $ this ->resumableParam ($ this ->resumableOption ['chunkNumber ' ]);
203- $ chunkSize = $ this ->resumableParam ($ this ->resumableOption ['chunkSize ' ]);
204- $ totalChunks = $ this ->resumableParam ($ this ->resumableOption ['totalChunks ' ]);
202+ $ chunkNumber = ( int ) $ this ->resumableParam ($ this ->resumableOption ['chunkNumber ' ]);
203+ $ chunkSize = ( int ) $ this ->resumableParam ($ this ->resumableOption ['chunkSize ' ]);
204+ $ totalChunks = ( int ) $ this ->resumableParam ($ this ->resumableOption ['totalChunks ' ]);
205205
206206 if (!$ this ->isChunkUploaded ($ identifier , $ filename , $ chunkNumber )) {
207207 $ chunkFile = $ this ->tmpChunkDir ($ identifier ) . DIRECTORY_SEPARATOR . $ this ->tmpChunkFilename ($ filename , $ chunkNumber );
0 commit comments