title: How to alert if there is a Dropzone error?
body: <p><strong>This is my controller, where I return error</strong></p>
  
  <pre><code>if(!empty($chckDocsDup)){
       $return['error'] = 1;
       return response()-&gt;json($return);
       exit();
   }
  </code></pre>
  
  <p>In my Dropzone I getting those error using <code>this.on('error', function())</code> but it failed to alert. Any alternative idea?</p>
  
  <pre><code>$(document).ready(function () {
      var uplodURLother = '{{url(ADMIN."/uploaddocument")}}';
      var metaTokenOther = $('meta[name="_token"]').attr('content');
      var uploaddoctypeOther = $('#uploaddoctype_other').val();
      Dropzone.options.myDropOther = {
      acceptedFiles: ".pdf,.doc,.docx",
      url: uplodURLother,
      sending: function(file, xhr, formData) {
          formData.append("_token", metaTokenOther);
          formData.append("doctype", uploaddoctypeOther);
          formData.append("candidateid", '{{$candidateDet['candidateid'] }}');
      },
        init: function() {
           this.on("removedfile", function(file) {
              $(".remv_"+file.doctype+"_"+file.filecnt).remove();
          });
          this.on('success', function(file, response) {
                  alert('hai');
            });   
              this.on('error', function(file, response) {
                 alert('response'); //This alert is not working
              });
        }
      };
  
  });
  </code></pre>