Closed vincentdsf closed 4 years ago
Updated Issue with more information
You can't do what you're attempting to do.
Use Firebase Functions to set server timestamp.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. You may also mark this issue as a "discussion" and I will leave this open.
Closing this issue after a prolonged period of inactivity. Fell free to reopen this issue, if this still affecting you.
Your Environment
Plugin version: 0.1.0
Platform: iOS
OS version: iOS13
Device manufacturer / model: emulator
Cordova version (
cordova -v
): 9.0.0 (cordova-lib@9.0.1)Cordova platform version (
cordova platform ls
): Installed platforms: ios 5.1.1 Available platforms: android ^8.0.0 browser ^6.0.0 electron ^1.0.0 osx ^5.0.0 windows ^7.0.0Plugin config provided to
#ready
:Expected Behavior
When trying to pass in params as parameter firestoreTimestamp: firebase.firestore.FieldValue.serverTimestamp() I want the Position-Doc to be successfully stored in Firstore with the Serverside Timestamp.
Actual Behavior
The following error comes and positions dont get stored in Firestore: WARN: - BackgroundGeolocation configuration error: TypeError: JSON.stringify cannot serialize cyclic structures.
Steps to Reproduce
Context
I want Firestore Documents created by Background Plugin to have a timestamp created on server-side. If the user changes the phones time settings, the positions become invalid if an application depends on the correct timestamp.
Debug logs
WARN: - BackgroundGeolocation configuration error: TypeError: JSON.stringify cannot serialize cyclic structures.
Logs
``` PASTE_YOUR_LOGS_HERE ```Anything else I can do to achieve my goal or is this something that needs to be implemented?