New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

balena-temen

Package Overview
Dependencies
Maintainers
3
Versions
27
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

balena-temen - npm Package Compare versions

Comparing version 0.5.6 to 0.5.7-fix-warnings-f5b79a2f08857f49064eddc9c9762e43a97e96fd

55

balena_temen_main.js

@@ -35,14 +35,14 @@ var wasm;

* Evaluates the whole JSON
* @param {any} arg0
* @param {any} data
* @returns {any}
*/
module.exports.evaluate = function(arg0) {
return takeObject(wasm.evaluate(addHeapObject(arg0)));
module.exports.evaluate = function(data) {
return takeObject(wasm.evaluate(addHeapObject(data)));
};
module.exports.__wbg_getTime_ece6079ef900687a = function(arg0) {
module.exports.__wbg_getTime_4e9d2e4b6034a8e3 = function(arg0) {
return getObject(arg0).getTime();
};
module.exports.__wbg_new0_7a2568f251003178 = function() {
module.exports.__wbg_new0_b4c0f6100aa61878 = function() {
return addHeapObject(new Date());

@@ -80,38 +80,19 @@ };

const TextEncoder = require('util').TextEncoder;
let cachedTextEncoder = new TextEncoder('utf-8');
let WASM_VECTOR_LEN = 0;
let passStringToWasm;
if (typeof cachedTextEncoder.encodeInto === 'function') {
passStringToWasm = function(arg) {
let cachegetNodeBufferMemory = null;
function getNodeBufferMemory() {
if (cachegetNodeBufferMemory === null || cachegetNodeBufferMemory.buffer !== wasm.memory.buffer) {
cachegetNodeBufferMemory = Buffer.from(wasm.memory.buffer);
}
return cachegetNodeBufferMemory;
}
let size = arg.length;
let ptr = wasm.__wbindgen_malloc(size);
let writeOffset = 0;
while (true) {
const view = getUint8Memory().subarray(ptr + writeOffset, ptr + size);
const { read, written } = cachedTextEncoder.encodeInto(arg, view);
arg = arg.substring(read);
writeOffset += written;
if (arg.length === 0) {
break;
}
ptr = wasm.__wbindgen_realloc(ptr, size, size * 2);
size *= 2;
}
WASM_VECTOR_LEN = writeOffset;
return ptr;
};
} else {
passStringToWasm = function(arg) {
function passStringToWasm(arg) {
const buf = cachedTextEncoder.encode(arg);
const ptr = wasm.__wbindgen_malloc(buf.length);
getUint8Memory().set(buf, ptr);
WASM_VECTOR_LEN = buf.length;
return ptr;
};
const size = Buffer.byteLength(arg);
const ptr = wasm.__wbindgen_malloc(size);
getNodeBufferMemory().write(arg, ptr, size);
WASM_VECTOR_LEN = size;
return ptr;
}

@@ -118,0 +99,0 @@

/* tslint:disable */
/**
* Evaluates the whole JSON
* @param {any} arg0
* @param {any} data
* @returns {any}
*/
export function evaluate(arg0: any): any;
export function evaluate(data: any): any;

@@ -35,14 +35,14 @@ import * as wasm from './balena_temen_bg';

* Evaluates the whole JSON
* @param {any} arg0
* @param {any} data
* @returns {any}
*/
export function evaluate(arg0) {
return takeObject(wasm.evaluate(addHeapObject(arg0)));
export function evaluate(data) {
return takeObject(wasm.evaluate(addHeapObject(data)));
}
export function __wbg_getTime_ece6079ef900687a(arg0) {
export function __wbg_getTime_4e9d2e4b6034a8e3(arg0) {
return getObject(arg0).getTime();
}
export function __wbg_new0_7a2568f251003178() {
export function __wbg_new0_b4c0f6100aa61878() {
return addHeapObject(new Date());

@@ -78,6 +78,6 @@ }

let WASM_VECTOR_LEN = 0;
let cachedTextEncoder = new TextEncoder('utf-8');
let WASM_VECTOR_LEN = 0;
let passStringToWasm;

@@ -87,17 +87,24 @@ if (typeof cachedTextEncoder.encodeInto === 'function') {

let size = arg.length;
let ptr = wasm.__wbindgen_malloc(size);
let writeOffset = 0;
while (true) {
const view = getUint8Memory().subarray(ptr + writeOffset, ptr + size);
const { read, written } = cachedTextEncoder.encodeInto(arg, view);
arg = arg.substring(read);
writeOffset += written;
if (arg.length === 0) {
break;
let offset = 0;
{
const mem = getUint8Memory();
for (; offset < arg.length; offset++) {
const code = arg.charCodeAt(offset);
if (code > 0x7F) break;
mem[ptr + offset] = code;
}
ptr = wasm.__wbindgen_realloc(ptr, size, size * 2);
size *= 2;
}
WASM_VECTOR_LEN = writeOffset;
if (offset !== arg.length) {
arg = arg.slice(offset);
ptr = wasm.__wbindgen_realloc(ptr, size, size = offset + arg.length * 3);
const view = getUint8Memory().subarray(ptr + offset, ptr + size);
const ret = cachedTextEncoder.encodeInto(arg, view);
offset += ret.written;
}
WASM_VECTOR_LEN = offset;
return ptr;

@@ -108,6 +115,22 @@ };

const buf = cachedTextEncoder.encode(arg);
const ptr = wasm.__wbindgen_malloc(buf.length);
getUint8Memory().set(buf, ptr);
WASM_VECTOR_LEN = buf.length;
let size = arg.length;
let ptr = wasm.__wbindgen_malloc(size);
let offset = 0;
{
const mem = getUint8Memory();
for (; offset < arg.length; offset++) {
const code = arg.charCodeAt(offset);
if (code > 0x7F) break;
mem[ptr + offset] = code;
}
}
if (offset !== arg.length) {
const buf = cachedTextEncoder.encode(arg.slice(offset));
ptr = wasm.__wbindgen_realloc(ptr, size, size = offset + buf.length);
getUint8Memory().set(buf, ptr + offset);
offset += buf.length;
}
WASM_VECTOR_LEN = offset;
return ptr;

@@ -114,0 +137,0 @@ };

@@ -8,3 +8,3 @@ {

"description": "Templating engine for (not just) JSON",
"version": "0.5.6",
"version": "0.5.7-fix-warnings-f5b79a2f08857f49064eddc9c9762e43a97e96fd",
"license": "Apache-2.0",

@@ -11,0 +11,0 @@ "repository": {

Sorry, the diff of this file is not supported yet

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