triniwiz / nativescript-downloader

Apache License 2.0
32 stars 18 forks source link

createDownload() fails with an empty exception #13

Closed wanpeng2008 closed 6 years ago

wanpeng2008 commented 6 years ago
          let downloadUrl = 'http://dldir1.qq.com/weixin/android/weixin666android1300.apk';
         let downloader = new Downloader();
         let downloaderId;
          try {
             downloaderId =downloader.createDownload({
                  url: downloadUrl
              });
          }catch(e){
              alert(JSON.stringify(e))
          }

An empty exception "{}" is thrown. No other information.

env: nativescript@3.4.3; tns-core-modules@4.0.0; tns-android@3.4.2 nativescript-downloader@1.1.0

wanpeng2008 commented 6 years ago

Sorry for my mistake. I forgot to invoke Downloader.init() after the app launch