title: Call to a member function getClientOriginalExtension() on a non-object even with 'file' => true
body: <p>I am getting a "Call to a member function getClientOriginalExtension() on a non-object", even though I have taken advice I have found to eliminate it, including adding 'files' => true to my {{ Form::open }}. </p>
  
  <p>Any idea what step I am getting wrong?</p>
  
  <p><strong>EDIT</strong>  here is my routing</p>
  
  <pre><code>Route::resource('/contractors', 'ContractorController');
  Route::controller('/contractors', 'ContractorController');
  Route::post('/contractors/portfolio/{$id}', 'ContractorController@post_Portfolio');
  </code></pre>
  
  <p>Here is my controller: </p>
  
  <pre><code>public function post_Portfolio($id)
      {
  
      $contractor = Contractor::find($id);
      $input = Input::all();
      $rules = array(
        'fileToUpload' =&gt; 'image|max:3000',
    );
  
    $validation = Validator::make($input, $rules);
  
    if ($validation-&gt;fails())
    {
      return Response::make($validation-&gt;errors-&gt;first(), 400);
    }
      $file = Input::file('filesToUpload');
      $destinationPath = 'uploads/portfolio';
      $extension = $file-&gt;getClientOriginalExtension(); 
      $filename = str_random(12).".{$extension}";
      $upload_success = Input::file('filesToUpload')-&gt;move($destinationPath, $filename);
  
      if( $upload_success ) { 
  
          //create a new portfolio and transfer the inputs to the db
  
          $portfolio = new Portfolio;
          $contractor = Contractor::find($id);
          $portfolio-&gt;title       = Input::get('title');
          $portfolio-&gt;description     = Input::get('projectDetails');
          $portfolio-&gt;contractor_id   = Input::get('contractor_id');
          $portfolio-&gt;save();
  
          $photo = new ContractorPhoto;
          $photo-&gt;portfolio_id = $portfolio-&gt;id;
          $photo-&gt;path = $destinationPath ."/". $filename;
          $photo-&gt;save();
  
          // redirect
          Session::flash('message', 'Successfully updated profile!');
          return Redirect::to('contractors/');
  
      } else {
          Session::flash('message', 'Houston we have a problem!');
          return Redirect::to('contractors/'); 
      }
  
  
  
  }
  </code></pre>
  
  <p>And here is my view: </p>
  
  <pre><code>&lt;div class="span8 bdb bdb-larger"&gt;
          {{ Form::open(['url' =&gt; 'contractors/portfolio/{$id}','files' =&gt; true, 'method' =&gt; 'post', $contractor-&gt;id]) }}
              &lt;input type="hidden" name="contractor_id"  value="{{$contractor-&gt;id}}"&gt;
          &lt;div class="row"&gt;
              &lt;div class="span6"&gt;
                  &lt;label for="title"&gt;Project Name&lt;span class="required"&gt;*&lt;/span&gt;&lt;/label&gt;
                  &lt;input type="text" name="title" id="title"&gt;
                  &lt;input type="hidden" name="contractor_id"  value="{{$contractor-&gt;id}}"&gt;
              &lt;/div&gt;
          &lt;/div&gt;
  
  
          &lt;div class="row"&gt;
              &lt;div class="span6"&gt;
                  &lt;label for="projectDetails"&gt;Project Details &lt;span class="required"&gt;*&lt;/span&gt;&lt;/label&gt;
                  &lt;textarea name="projectDetails" class="row-fluid" id="projectDetails"&gt;&lt;/textarea&gt;
              &lt;/div&gt;
          &lt;/div&gt;
              &lt;div class="row"&gt;
              &lt;div class="span6"&gt;
                  &lt;div&gt; 
                  &lt;label for="filesToUpload"&gt;Cover Photo&lt;/label&gt;
                  &lt;input class="filestyle" type="file" name="filesToUpload[]" id="filesToUpload" multiple="multiple" /&gt;
                  &lt;script&gt;$(":file").filestyle({classInput: "input-small"});&lt;/script&gt;
                  &lt;/div&gt; 
              &lt;/div&gt;
          &lt;/div&gt;
  
          &lt;div class="row"&gt;
              &lt;div class="span6"&gt;
                  &lt;br /&gt;
                  &lt;div&gt; 
                  &lt;label for="photos"&gt;Additional Photos&lt;/label&gt;
                  &lt;input class="filestyle" type="file" name="filesToUpload[]" id="filesToUpload" multiple="multiple" /&gt;
                  &lt;script&gt;$(":file").filestyle({classInput: "input-small"});&lt;/script&gt;
  
                  &lt;/div&gt; 
              &lt;/div&gt;
          &lt;/div&gt;
          &lt;div class="row"&gt;
              &lt;div class="span6"&gt;
                  &lt;output id="filesInfo"&gt;&lt;/output&gt;
              &lt;/div&gt;
          &lt;/div&gt;
  
          &lt;div class="row"&gt;
              &lt;div class="span6"&gt;
                  &lt;br /&gt;&lt;input type="submit" id="btn-porfolio" class="btn btn-primary btn-read-more" value="Submit"&gt;
              &lt;/div&gt;
          &lt;/div&gt;
      &lt;/div&gt;
      {{form::close()}}
  
  &lt;/div&gt; 
  </code></pre>
  
  <p>{{ HTML::script('assets/js/scripts/portfolio.js') }}</p>