title: Metadata version mismatch found version 4, expected 3 in barcode-scanner
body: <p>Currently I am working with barcode-scanner reader in ionic. 
  While <code>ionic serve</code> the build is successfully processing. 
  But <code>ionic cordova build android --prod --release</code> 
  I am getting below error. </p>
  
  <blockquote>
    <p>Error: Metadata version mismatch for module
    /var/www/html/mobile/node_modules/@ionic-native/barcode-scanner/index.d.ts,
    found version 4, expected 3
            at StaticSymbolResolver.getModuleMetadata (/var/www/html/mobile/node_modules/@angular/compiler/bundles/compiler.umd.js:24474:34)
            at StaticSymbolResolver._createSymbolsOf (/var/www/html/mobile/node_modules/@angular/compiler/bundles/compiler.umd.js:24260:46)
            at StaticSymbolResolver.getSymbolsOf (/var/www/html/mobile/node_modules/@angular/compiler/bundles/compiler.umd.js:24241:14)
            at /var/www/html/mobile/node_modules/@angular/compiler/bundles/compiler.umd.js:23023:30
            at Array.forEach ()
            at extractProgramSymbols (/var/www/html/mobile/node_modules/@angular/compiler/bundles/compiler.umd.js:23022:79)
            at AotCompiler.compileAll (/var/www/html/mobile/node_modules/@angular/compiler/bundles/compiler.umd.js:22720:47)
            at CodeGenerator.codegen (/var/www/html/mobile/node_modules/@angular/compiler-cli/src/codegen.js:30:14)
            at Function.NgTools_InternalApi_NG_2.codeGen (/var/www/html/mobile/node_modules/@angular/compiler-cli/src/ngtools_api.js:61:30)
            at /var/www/html/mobile/node_modules/@ionic/app-scripts/dist/aot/aot-compiler.js:182:73</p>
  </blockquote>
  
  <p>I did't know what to do. 
  Please give me some suggestions to resolve this issue.</p>
  
  <pre><code>import {BarcodeScanner} from "@ionic-native/barcode-scanner";
  
  
  scanQR() {
          let options = {
              prompt: "Place a Qr code inside the scan area",
          };
  
          this._barcodeScanner.scan(options).then((barcodeData) =&gt; {
              if (barcodeData.cancelled) {
                  console.log("User cancelled the action!");
                  return false;
              }
              if (barcodeData.text) {
                  alert("We got a barcode\n" +
                      "Result: " + barcodeData.text + "\n" +
                      "Format: " + barcodeData.format + "\n" +
                      "Cancelled: " + barcodeData.cancelled);
                  this.navCtrl.pop();
              } else {
                  this.navCtrl.pop();
              }
          }, (err) =&gt; {
              alert(err);
          });
      }
  </code></pre>
  
  <p>system ionic info</p>
  
  <pre><code>cli packages: (/usr/local/lib/node_modules)
  
      @ionic/cli-utils  : 1.19.2
      ionic (Ionic CLI) : 3.20.0
  
  global packages:
  
      cordova (Cordova CLI) : 7.1.0 
  
  local packages:
  
      @ionic/app-scripts : 3.1.11
      Cordova Platforms  : android 6.3.0 browser 5.0.3
      Ionic Framework    : ionic-angular 3.6.0
  
  System:
  
      Android SDK Tools : 26.1.1
      Node              : v9.2.0
      npm               : 6.1.0 
      OS                : Linux 4.15
  
  Environment Variables:
  
      ANDROID_HOME : /home/anandhsp21/Android/Sdk
  
  Misc:
  
      backend : legacy
  </code></pre>