Eventualy I found a solution for my problem by adding the following code:
navigation = navigator.geolocation;
navigation.getCurrentPosition(success, failure);
function success(position){
$parameters.Lat = position.coords.latitude;
$parameters.Long = position.coords.longitude;
$resolve();
}
function failure(error){
console.log(error.code);
$resolve();
}
In this case when rejected by the user it will respond with a 1 code and will not block the whole flow.