title: Barcode Scanner not working on Android when using ngCordova and Ionic
body: <p>The application so far is just a button that opens the barcode scanner and displays the results when it returns, easy enough. However, when you press the button the following screen shows up: <a href="http://i.imgur.com/2XOPLvU.png?1" rel="nofollow">http://i.imgur.com/2XOPLvU.png?1</a></p>
  
  <p>Restarting my device made no difference. Camera works with other applications that require the use of the camera. </p>
  
  <p>Here is the code for the Controller:</p>
  
  <pre><code>QRKeeper.controller('ScannerController', function($scope, $cordovaBarcodeScanner){
  
    //Function that runs the scanner 
    $scope.scanCode = function(){
  
      console.log("Scan button pressed");
  
        $cordovaBarcodeScanner.scan()
          .then(
            function(response){
              if(!response.cancelled){
                console.log("Scan successful");
              } else {
                console.log("Scan cancelled");
              }
            }, function(error){
              console.log("Error when trying to read code");
            }
          );
    }
  });
  </code></pre>
  
  <p>Wrapping it in <code>deviceready</code> as recommended on the Ionic website made no difference. When executing, <code>chrome://inspect</code> did not show any error logs.</p>
  
  <p>Thank you!</p>
  
  <p>I am using this barcode scanner <a href="https://github.com/phonegap/phonegap-plugin-barcodescanner" rel="nofollow">https://github.com/phonegap/phonegap-plugin-barcodescanner</a></p>
  
  <p>Using the ngCordova plugin <a href="http://ngcordova.com/docs/plugins/barcodeScanner/" rel="nofollow">http://ngcordova.com/docs/plugins/barcodeScanner/</a></p>