How to make difference between folders and files
<p>I am stuck in making difference between folders and files in Javascript. In this problem:</p>

<ol>
<li>If I am trying to drag any folder then there should show any warning message and </li>
<li>If I am dragging any files(like zip file, rar file, doc file, txt file etc.) (If file name is like this way:- aparna.verma then also it should treat as file only not as folder or if file name is aparna-verma then also it should treat as file only not as folder.) then show warning message.</li>
<li>I used this line of code:</li>
</ol>

<blockquote>
<pre><code>if (new_file.type !== '') 
{
    new_list.push(new_file);
}
</code></pre>
</blockquote>
