@@ -69,7 +69,7 @@ public function addResource($name, $resource, array $options = [])
6969 if (empty ($ options ['filename ' ])) {
7070 $ options ['filename ' ] = null ;
7171 $ uri = $ stream ->getMetadata ('uri ' );
72- if (substr ($ uri , 0 , 6 ) !== ' php:// ' ) {
72+ if (' php:// ' !== substr ($ uri , 0 , 6 )) {
7373 $ options ['filename ' ] = $ uri ;
7474 }
7575 }
@@ -121,7 +121,7 @@ public function build()
121121 */
122122 private function prepareHeaders ($ name , StreamInterface $ stream , $ filename , array &$ headers )
123123 {
124- $ hasFilename = $ filename === ' 0 ' || $ filename ;
124+ $ hasFilename = ' 0 ' === $ filename || $ filename ;
125125
126126 // Set a default content-disposition header if one was not provided
127127 if (!$ this ->hasHeader ($ headers , 'content-disposition ' )) {
@@ -190,7 +190,7 @@ private function hasHeader(array $headers, $key)
190190 */
191191 public function getBoundary ()
192192 {
193- if ($ this -> boundary === null ) {
193+ if (null === $ this -> boundary ) {
194194 $ this ->boundary = uniqid ('' , true );
195195 }
196196
@@ -214,7 +214,7 @@ public function setBoundary($boundary)
214214 */
215215 private function getMimetypeHelper ()
216216 {
217- if ($ this -> mimetypeHelper === null ) {
217+ if (null === $ this -> mimetypeHelper ) {
218218 $ this ->mimetypeHelper = new ApacheMimetypeHelper ();
219219 }
220220
0 commit comments