@adventurelabs/scout-core 1.0.19 → 1.0.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/helpers/tags.js +0 -26
- package/package.json +1 -1
package/dist/helpers/tags.js
CHANGED
|
@@ -171,19 +171,6 @@ export async function get_event_and_tags_by_event_id(event_id) {
|
|
|
171
171
|
data: null,
|
|
172
172
|
};
|
|
173
173
|
}
|
|
174
|
-
// Debug the raw event data from database
|
|
175
|
-
console.log("Raw event data from DB:", {
|
|
176
|
-
eventId: data[0].id,
|
|
177
|
-
mediaUrl: data[0].media_url,
|
|
178
|
-
filePath: data[0].file_path,
|
|
179
|
-
message: data[0].message,
|
|
180
|
-
deviceId: data[0].device_id,
|
|
181
|
-
location: data[0].location,
|
|
182
|
-
locationType: typeof data[0].location,
|
|
183
|
-
hasCoordinates: data[0].location &&
|
|
184
|
-
typeof data[0].location === "object" &&
|
|
185
|
-
"coordinates" in data[0].location,
|
|
186
|
-
});
|
|
187
174
|
// Transform location to latitude/longitude with better error handling
|
|
188
175
|
let latitude = null;
|
|
189
176
|
let longitude = null;
|
|
@@ -236,20 +223,7 @@ export async function get_event_and_tags_by_event_id(event_id) {
|
|
|
236
223
|
earthranger_url: data[0].earthranger_url,
|
|
237
224
|
file_path: data[0].file_path,
|
|
238
225
|
};
|
|
239
|
-
// Debug before signed URL generation
|
|
240
|
-
console.log("Before signed URL generation:", {
|
|
241
|
-
eventId: transformedData.id,
|
|
242
|
-
mediaUrl: transformedData.media_url,
|
|
243
|
-
filePath: transformedData.file_path,
|
|
244
|
-
hasFilePath: !!transformedData.file_path,
|
|
245
|
-
});
|
|
246
226
|
// Add signed URL to event using the same client
|
|
247
227
|
const eventWithSignedUrl = await addSignedUrlToEvent(transformedData, supabase);
|
|
248
|
-
// Debug after signed URL generation
|
|
249
|
-
console.log("After signed URL generation:", {
|
|
250
|
-
eventId: eventWithSignedUrl.id,
|
|
251
|
-
mediaUrl: eventWithSignedUrl.media_url,
|
|
252
|
-
filePath: eventWithSignedUrl.file_path,
|
|
253
|
-
});
|
|
254
228
|
return IWebResponse.success(eventWithSignedUrl).to_compatible();
|
|
255
229
|
}
|