@meri-imperiumi/signalk-triplogger 1.2.0 → 1.3.0

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/Logger.js CHANGED
@@ -23,6 +23,9 @@ class Logger {
23
23
  }
24
24
 
25
25
  inTrip() {
26
+ if (this.state === null && this.log.started && !this.log.ended) {
27
+ return true;
28
+ }
26
29
  if (this.state === 'sailing' || this.state === 'motoring') {
27
30
  return true;
28
31
  }
package/README.md CHANGED
@@ -6,6 +6,8 @@ The plugin monitors vessel `navigation.state` as set by the [signalk-autostate](
6
6
 
7
7
  ## Changes
8
8
 
9
+ * 1.3.0 (June 10th 2026)
10
+ - Don't start a new trip at startup if there's an ongoing one
9
11
  * 1.2.0 (April 27th 2023)
10
12
  - Added support for populating `navigation.log` for totals
11
13
  * 1.1.1 (February 28th 2023)
package/index.js CHANGED
@@ -181,7 +181,7 @@ module.exports = (app) => {
181
181
  handleState(v.value);
182
182
  }
183
183
  if (v.path === 'navigation.position') {
184
- if (Number.isNaN(Number(v.value.latitude))
184
+ if (!v.path || Number.isNaN(Number(v.value.latitude))
185
185
  || Number.isNaN(Number(v.value.longitude))) {
186
186
  return;
187
187
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@meri-imperiumi/signalk-triplogger",
3
- "version": "1.2.0",
3
+ "version": "1.3.0",
4
4
  "description": "Log the length of the current trip",
5
5
  "main": "index.js",
6
6
  "scripts": {