Skip to content

Commit

Permalink
Merge pull request #56 from Parsely/issue/55-fix_npe_in_get_add_key
Browse files Browse the repository at this point in the history
fix: initialize deviceInfo before putting adKey there
  • Loading branch information
wzieba authored Jun 5, 2023
2 parents 5a8ab29 + e73dbc6 commit b3b5c99
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,6 @@ protected ParselyTracker(String siteId, int flushInterval, Context c) {
this.rootUrl = "https://p1.parsely.com/";
this.queueSizeLimit = 50;
this.storageSizeLimit = 100;
this.deviceInfo = this.collectDeviceInfo();
this.timer = new Timer();
this.isDebug = false;

Expand Down Expand Up @@ -757,6 +756,7 @@ protected String doInBackground(Void... params) {
@Override
protected void onPostExecute(String advertId) {
adKey = advertId;
deviceInfo = collectDeviceInfo();
deviceInfo.put("parsely_site_uuid", adKey);
}

Expand Down

0 comments on commit b3b5c99

Please sign in to comment.