title: In node.js how to check whether the particular write stream is opened or not
body: <p>Before opening the stream need to check whether the stream is already opened or not</p>
  
  <pre><code>var fs=require('fs');
  var stream=fs.createWriteStream(filePath, {flags: 'a'});
  stream.on('open',function(){
  
  
  });
  </code></pre>