Socket
Socket
Sign inDemoInstall

php-serialize

Package Overview
Dependencies
Maintainers
1
Versions
24
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

php-serialize - npm Package Compare versions

Comparing version 4.0.2 to 4.1.0

1

lib/cjs/helpers.js
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.getClass = exports.getIncompleteClass = exports.isInteger = exports.getByteLength = exports.__PHP_Incomplete_Class = void 0;
// eslint-disable-next-line camelcase,@typescript-eslint/class-name-casing

@@ -4,0 +5,0 @@ var __PHP_Incomplete_Class = /** @class */ (function () {

@@ -6,2 +6,3 @@ "use strict";

Object.defineProperty(exports, "__esModule", { value: true });
exports.isSerialized = exports.unserialize = exports.serialize = void 0;
var unserialize_1 = __importDefault(require("./unserialize"));

@@ -8,0 +9,0 @@ exports.unserialize = unserialize_1.default;

@@ -13,2 +13,18 @@ "use strict";

};
var __read = (this && this.__read) || function (o, n) {
var m = typeof Symbol === "function" && o[Symbol.iterator];
if (!m) return o;
var i = m.call(o), r, ar = [], e;
try {
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
}
catch (error) { e = { error: error }; }
finally {
try {
if (r && !r.done && (m = i["return"])) m.call(i);
}
finally { if (e) throw e.error; }
}
return ar;
};
var __importDefault = (this && this.__importDefault) || function (mod) {

@@ -59,2 +75,8 @@ return (mod && mod.__esModule) ? mod : { "default": mod };

}
if (item instanceof Map) {
return "a:" + item.size + ":{" + Array.from(item.entries()).map(function (_a) {
var _b = __read(_a, 2), value = _b[0], key = _b[1];
return "" + serialize(value, scope) + serialize(key, scope);
}) + "}";
}
var constructorName = getClassNamespace(item, scope);

@@ -61,0 +83,0 @@ if (typeof item.serialize === 'function') {

@@ -12,2 +12,18 @@ var __assign = (this && this.__assign) || function () {

};
var __read = (this && this.__read) || function (o, n) {
var m = typeof Symbol === "function" && o[Symbol.iterator];
if (!m) return o;
var i = m.call(o), r, ar = [], e;
try {
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
}
catch (error) { e = { error: error }; }
finally {
try {
if (r && !r.done && (m = i["return"])) m.call(i);
}
finally { if (e) throw e.error; }
}
return ar;
};
import invariant from 'assert';

@@ -54,2 +70,8 @@ import { isInteger, getByteLength } from './helpers';

}
if (item instanceof Map) {
return "a:" + item.size + ":{" + Array.from(item.entries()).map(function (_a) {
var _b = __read(_a, 2), value = _b[0], key = _b[1];
return "" + serialize(value, scope) + serialize(key, scope);
}) + "}";
}
var constructorName = getClassNamespace(item, scope);

@@ -56,0 +78,0 @@ if (typeof item.serialize === 'function') {

2

package.json
{
"name": "php-serialize",
"version": "4.0.2",
"version": "4.1.0",
"description": "PHP serialize/unserialize in Javascript",

@@ -5,0 +5,0 @@ "main": "lib/cjs/index.js",

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