title: Using Phonegap CLI - Barcode scanner not working
body: <p>I developing an app for iOS and Android using PhoneGap 3.4.0 from the command line interface, and want to make use of the BarcodeScanner plugin. The problem is that the scanner does not actually do anything when called by my app. The camera does not come up. By using console.log with Safari developer tools, I can tell that the scan function does exist and is getting called... it just isn't doing anything. </p>
  
  <p>I installed the scanner plugin like this:
  <code>phonegap plugin add https://github.com/wildabeast/BarcodeScanner</code></p>
  
  <p>In the index.html, included the javascripts like this:</p>
  
  <pre><code>  &lt;script src="phonegap.js"&gt;&lt;/script&gt;
    &lt;script src="barcodescanner.js"&gt;&lt;/script&gt;
  </code></pre>
  
  <p>In config.xml, added this: </p>
  
  <p><code>&lt;gap:plugin name="com.phonegap.plugins.barcodescanner" /&gt;</code></p>
  
  <p>When I set scanner variable like this it logs that there is a BarcodeScanner, and it does have a function <code>scan</code>, but then when I call the function <code>scan</code> nothing happens. (the camera does not open).</p>
  
  <pre><code>var scanner = cordova.plugins.barcodeScanner;
  console.log(scanner)  // =&gt;  BarcodeScanner
  </code></pre>
  
  <p>This is how I'm calling the <code>scan</code> function:</p>
  
  <pre><code>scanner.scan( function (result) {
    ... my code here...
  } );
  </code></pre>
  
  <p>Any ideas? I'd really appreciate any help or pointers in how to get the barcodeScanner to work with PhoneGap. </p>