Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

workers-firebase

Package Overview
Dependencies
Maintainers
1
Versions
29
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

workers-firebase - npm Package Compare versions

Comparing version 0.0.12 to 0.0.13

4

dist/firestore/document.js

@@ -19,6 +19,6 @@ import { decode, decodeValue } from './serializer';

get exists() {
return !!this[docSymbol].fields;
return !!this[docSymbol]?.fields;
}
data() {
return this[docSymbol].fields && decode(this.ref.firestore, this[docSymbol].fields) || null;
return this[docSymbol]?.fields && decode(this.ref.firestore, this[docSymbol].fields) || null;
}

@@ -25,0 +25,0 @@ get(field) {

@@ -58,3 +58,3 @@ var _a;

const segments = typeof path === 'string' ? trim(path).split('/') : path;
if (segments.length % 2 === 0)
if (segments.length % 2 !== 0)
throw new Error('A document reference must have an even number of segments');

@@ -61,0 +61,0 @@ this.segments = segments;

{
"name": "workers-firebase",
"version": "0.0.12",
"version": "0.0.13",
"scripts": {

@@ -5,0 +5,0 @@ "start": "tsc --watch",

@@ -27,7 +27,7 @@ import { DocumentReference } from './reference';

get exists() {
return !!this[docSymbol].fields;
return !!this[docSymbol]?.fields;
}
data() {
return this[docSymbol].fields && decode(this.ref.firestore, this[docSymbol].fields) || null;
return this[docSymbol]?.fields && decode(this.ref.firestore, this[docSymbol].fields) || null;
}

@@ -34,0 +34,0 @@

@@ -67,3 +67,3 @@ import type {

const segments = typeof path === 'string' ? trim(path).split('/') : path;
if (segments.length % 2 === 0) throw new Error('A document reference must have an even number of segments');
if (segments.length % 2 !== 0) throw new Error('A document reference must have an even number of segments');
this.segments = segments;

@@ -70,0 +70,0 @@ }

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc