<commit_before>package com.github.reactnativecommunity.location;

import android.Manifest;
import android.app.Activity;
import android.content.Intent;
import android.content.IntentSender;
import android.content.pm.PackageManager;
import android.location.Location;
import android.support.annotation.NonNull;
import android.support.v4.app.ActivityCompat;

import com.facebook.react.bridge.Arguments;
import com.facebook.react.bridge.Promise;
import com.facebook.react.bridge.ReactApplicationContext;
import com.facebook.react.bridge.ReadableMap;
import com.facebook.react.bridge.ReadableType;
import com.facebook.react.bridge.WritableArray;
import com.google.android.gms.common.api.ResolvableApiException;
import com.google.android.gms.location.FusedLocationProviderClient;
import com.google.android.gms.location.LocationCallback;
import com.google.android.gms.location.LocationRequest;
import com.google.android.gms.location.LocationResult;
import com.google.android.gms.location.LocationServices;
import com.google.android.gms.location.LocationSettingsRequest;
import com.google.android.gms.location.LocationSettingsResponse;
import com.google.android.gms.location.SettingsClient;
import com.google.android.gms.tasks.OnFailureListener;
import com.google.android.gms.tasks.OnSuccessListener;
import com.google.android.gms.tasks.Task;

import java.lang.ref.WeakReference;

public class RNPlayServicesLocationProvider implements RNLocationProvider {
    private static final int REQUEST_CHECK_SETTINGS = 12341234;

    private final ReactApplicationContext context;
    private final FusedLocationProviderClient locationProvider;
    private final SettingsClient locationSettingsClient;

    private LocationRequest locationRequest = new LocationRequest();
    private boolean isUpdatingLocation = false;

    private WeakReference<Activity> pendingConfigureActivity = null;
    private ReadableMap pendingConfigureOptions = null;
    private Promise pendingConfigurePromise = null;

    public RNPlayServicesLocationProvider(Activity activity, ReactApplicationContext context) {<commit_msg>fix: Avoid an Android crash by using a lower request code<commit_after>package com.github.reactnativecommunity.location;

import android.Manifest;
import android.app.Activity;
import android.content.Intent;
import android.content.IntentSender;
import android.content.pm.PackageManager;
import android.location.Location;
import android.support.annotation.NonNull;
import android.support.v4.app.ActivityCompat;

import com.facebook.react.bridge.Arguments;
import com.facebook.react.bridge.Promise;
import com.facebook.react.bridge.ReactApplicationContext;
import com.facebook.react.bridge.ReadableMap;
import com.facebook.react.bridge.ReadableType;
import com.facebook.react.bridge.WritableArray;
import com.google.android.gms.common.api.ResolvableApiException;
import com.google.android.gms.location.FusedLocationProviderClient;
import com.google.android.gms.location.LocationCallback;
import com.google.android.gms.location.LocationRequest;
import com.google.android.gms.location.LocationResult;
import com.google.android.gms.location.LocationServices;
import com.google.android.gms.location.LocationSettingsRequest;
import com.google.android.gms.location.LocationSettingsResponse;
import com.google.android.gms.location.SettingsClient;
import com.google.android.gms.tasks.OnFailureListener;
import com.google.android.gms.tasks.OnSuccessListener;
import com.google.android.gms.tasks.Task;

import java.lang.ref.WeakReference;

public class RNPlayServicesLocationProvider implements RNLocationProvider {
    private static final int REQUEST_CHECK_SETTINGS = 1234;

    private final ReactApplicationContext context;
    private final FusedLocationProviderClient locationProvider;
    private final SettingsClient locationSettingsClient;

    private LocationRequest locationRequest = new LocationRequest();
    private boolean isUpdatingLocation = false;

    private WeakReference<Activity> pendingConfigureActivity = null;
    private ReadableMap pendingConfigureOptions = null;
    private Promise pendingConfigurePromise = null;

    public RNPlayServicesLocationProvider(Activity activity, ReactApplicationContext context) {
{'fraction_non_alphanumeric': 0.07851043643263757, 'fraction_numerical': 0.003320683111954459, 'mean_word_length': 6.653357531760435, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2659210', 'n_tokens_mistral': 1108, 'n_tokens_neox': 1084, 'n_words': 220}