@@ -135,6 +135,7 @@ public static Hashtable<String, Object> buildFeedbackEvent(
135135 String upcomingModifier , String upcomingName , String previousInstruction , String previousType ,
136136 String previousModifier , String previousName , int distance , int duration , int stepDistanceRemaining ,
137137 int stepDurationRemaining , int stepCount , int originalStepCount ) {
138+ NavigationLocation navigationLoc = new NavigationLocation ();
138139 Hashtable <String , Object > event = getMetadata (sdKIdentifier , sdkVersion , sessionIdentifier ,
139140 lat , lng , geometry , profile , estimatedDistance , estimatedDuration , rerouteCount ,
140141 isSimulation , originalRequestIdentifier , requestIdentifier , originalGeometry ,
@@ -150,12 +151,12 @@ public static Hashtable<String, Object> buildFeedbackEvent(
150151 event .put (KEY_START_TIMESTAMP , TelemetryUtils .generateCreateDateFormatted (startTimestamp ));
151152 event .put (KEY_FEEDBACK_TYPE , feedbackType );
152153 if (locationsBefore != null ) {
153- event .put (KEY_LOCATIONS_BEFORE , locationsBefore );
154+ event .put (KEY_LOCATIONS_BEFORE , navigationLoc . getSerializedJson ( locationsBefore ) );
154155 } else {
155156 event .put (KEY_LOCATIONS_BEFORE , JSONObject .NULL );
156157 }
157158 if (locationsAfter != null ) {
158- event .put (KEY_LOCATIONS_AFTER , locationsAfter );
159+ event .put (KEY_LOCATIONS_AFTER , navigationLoc . getSerializedJson ( locationsAfter ) );
159160 } else {
160161 event .put (KEY_LOCATIONS_AFTER , JSONObject .NULL );
161162 }
@@ -180,6 +181,7 @@ public static Hashtable<String, Object> buildRerouteEvent(
180181 String upcomingName , String previousInstruction , String previousType , String previousModifier ,
181182 String previousName , int distance , int duration , int stepDistanceRemaining , int stepDurationRemaining ,
182183 int stepCount , int originalStepCount ) {
184+ NavigationLocation navigationLoc = new NavigationLocation ();
183185 Hashtable <String , Object > event = getMetadata (sdKIdentifier , sdkVersion , sessionIdentifier ,
184186 lat , lng , geometry , profile , estimatedDistance , estimatedDuration , rerouteCount ,
185187 isSimulation , originalRequestIdentifier , requestIdentifier , originalGeometry ,
@@ -191,12 +193,12 @@ public static Hashtable<String, Object> buildRerouteEvent(
191193 event .put (KEY_FEEDBACK_ID , feedbackId );
192194 event .put (KEY_START_TIMESTAMP , TelemetryUtils .generateCreateDateFormatted (startTimestamp ));
193195 if (locationsBefore != null ) {
194- event .put (KEY_LOCATIONS_BEFORE , locationsBefore );
196+ event .put (KEY_LOCATIONS_BEFORE , navigationLoc . getSerializedJson ( locationsBefore ) );
195197 } else {
196198 event .put (KEY_LOCATIONS_BEFORE , JSONObject .NULL );
197199 }
198200 if (locationsAfter != null ) {
199- event .put (KEY_LOCATIONS_AFTER , locationsAfter );
201+ event .put (KEY_LOCATIONS_AFTER , navigationLoc . getSerializedJson ( locationsAfter ) );
200202 } else {
201203 event .put (KEY_LOCATIONS_AFTER , JSONObject .NULL );
202204 }
0 commit comments