Ionic3 imagepicker open gallery ERROR:((

Hii Everyone, I encountered an error, help me:))?

    openGallery() {
    console.log("oepn galery");
    this.loadfoto = 0;
    if (this.platform.is('android')) {
        console.log("if androidk");
        const options: ImagePickerOptions = {
            quality: 80,
        }

        let fotoloading: Loading = this.loading.create({
            content: 'Please wait...'
        });
        console.log("this.imagepicert");
        try {
            console.log("try");
            //close app in this line :// 
            this.imagePicker.getPictures(options).then(results => {
                console.log("image iii");

                this.galleryimagesize = results.length;
                for (var i = 0; i < results.length; i++) {
                    console.log("for için");

                    this.base64.encodeFile(results[i]).then((base64File: string) => {
                        var re = 'data:image/*;charset=utf-8;base64,';
                        base64File = base64File.replace(re, "");
                        let attachment: AttachmentObj = {
                            field: "resimler",
                            parentType: "Sehitaile",
                            role: "Attachment",
                            name: "image.jpg",
                            file: 'data:image/jpeg;base64,' + base64File,
                            type: "image/jpeg",
                            size: base64File.length,
                        };

                        this.attachments.push(attachment);

                    })
                }
                fotoloading.dismiss();
                this.attachmentsize = this.attachmentsize + this.galleryimagesize;
                this.fotoyukleniyormu = true;

            }, (err) => {
                console.log(err)
            });
        } catch (e) {
            console.log(e);
        }
    }
    else {
        const options: ImagePickerOptions = {
            maximumImagesCount: 3 - this.attachmentsize,
            quality: 70,
        }
        this.imagePicker.getPictures(options).then(results => {
            this.galleryimagesize = results.length;
            for (var i = 0; i < results.length; i++) {
                var itemSrc = results[i].replace(/^file:\/\//, '');
                this.base64.encodeFile(itemSrc).then((base64File: string) => {
                    this.imagetype = base64File.substring(5, 14);
                    if (this.imagetype == "image/jpe")
                        this.imagetype = "image/jpeg";
                    else
                        this.imagetype = "image/png";
                    let attachment: AttachmentObj = {
                        field: "resimler",
                        parentType: "Sehitaile",
                        role: "Attachment",
                        name: "image.jpg",
                        file: base64File,
                        type: this.imagetype,
                        size: base64File.length,
                    };
                    this.attachments.push(attachment);

                })

            }
            this.attachmentsize = this.attachmentsize + this.galleryimagesize;
            this.fotoyukleniyormu = true;

        }, (err) => {
            console.log(err)
        });
    }

}

I want to select photo from gallery, it’s okey ios, but android is not okey:///

" this.imagePicker.getPictures(options).then(results => { " <<— the application closes when it comes to this line. no error no warning. just close app

when an intermediate application closed, I received a notification that says “background tracking enabled”.

how should i proceed, can you help me.