didRangeBeaconsInRegion returns a empty beacons array

Hello there,I’m using ionic ibeacon library to detect beacons.My app is working on couple devices I have tested but it doesnt find beacons in one device .It has location permission like as the other devices.But it always return an empty beacons array. ( device is asus zenphone 3 laser ,android 7.1.1 and bluetooth is working )

import { Injectable } from ‘@angular/core’;
import { Platform, Events } from ‘ionic-angular’;
import { IBeacon } from “@ionic-native/ibeacon”;

@Injectable()
export class BeaconProvider {
delegate: any;
region: any;
constructor(
public platform: Platform,
public events: Events,
private iBeacon: IBeacon
) { this.initialise(); }

initialise(): any {
let promise = new Promise((resolve, reject) => {
if (this.platform.is(“cordova”)) {
// Request permission to use location on iOS
this.iBeacon.requestAlwaysAuthorization();
// create a new delegate and register it with the native layer
this.delegate = this.iBeacon.Delegate();
// this.iBeacon.locationManager.setDelegate(delegate);
// Subscribe to some of the delegate’s event handlers
this.delegate.didRangeBeaconsInRegion().subscribe(
data => {
this.events.publish(“didRangeBeaconsInRegion”, data);
console.log(“didRangebeacons__” + JSON.stringify(data)); // empty beacons array
},
error => console.error()
);
// setup a beacon region 8ce8e4a6-5fb0-4cd3-ba1a-214adac9f6da
this.region = this.iBeacon.BeaconRegion(“deskBeacon”, “e2c56db5-dffb-48d2-b060-d0f5a71096e0”);
// start ranging
this.iBeacon
.startRangingBeaconsInRegion(this.region)
.then(
() => {
resolve(true);
},
error => {
console.error("Failed to begin monitoring: ", error);
resolve(false);
}
);
} else {
resolve(false);
}
});

return promise;

}
}

Finally I found the problem ,in that device ,location is not enabled by app so beacon array is empty.When I enable location from android ,it show the beacons.