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

medusa-core-utils

Package Overview
Dependencies
Maintainers
2
Versions
458
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

medusa-core-utils - npm Package Compare versions

Comparing version 1.1.0 to 1.1.1-next.57

33

dist/validator.js

@@ -29,3 +29,36 @@ "use strict";

_joi["default"].dateFilter = function () {
return _joi["default"].object({
lt: _joi["default"].alternatives(_joi["default"].date().timestamp("unix"), _joi["default"].date()),
gt: _joi["default"].alternatives(_joi["default"].date().timestamp("unix"), _joi["default"].date()),
gte: _joi["default"].alternatives(_joi["default"].date().timestamp("unix"), _joi["default"].date()),
lte: _joi["default"].alternatives(_joi["default"].date().timestamp("unix"), _joi["default"].date())
});
};
_joi["default"].orderFilter = function () {
return _joi["default"].object().keys({
id: _joi["default"].string(),
q: _joi["default"].string(),
status: _joi["default"].array().items(_joi["default"].string().valid("pending", "completed", "archived", "canceled", "requires_action")).single(),
fulfillment_status: _joi["default"].array().items(_joi["default"].string().valid("not_fulfilled", "fulfilled", "partially_fulfilled", "shipped", "partially_shipped", "canceled", "returned", "partially_returned", "requires_action")).single(),
payment_status: _joi["default"].array().items(_joi["default"].string().valid("captured", "awaiting", "not_paid", "refunded", "partially_refunded", "canceled", "requires_action")).single(),
display_id: _joi["default"].string(),
cart_id: _joi["default"].string(),
offset: _joi["default"].string(),
limit: _joi["default"].string(),
expand: _joi["default"].string(),
fields: _joi["default"].string(),
customer_id: _joi["default"].string(),
email: _joi["default"].string(),
region_id: _joi["default"].string(),
currency_code: _joi["default"].string(),
tax_rate: _joi["default"].string(),
canceled_at: _joi["default"].dateFilter(),
created_at: _joi["default"].dateFilter(),
updated_at: _joi["default"].dateFilter()
});
};
var _default = _joi["default"];
exports["default"] = _default;

4

package.json
{
"name": "medusa-core-utils",
"version": "1.1.0",
"version": "1.1.1-next.57+60f16491",
"description": "Core utils for Medusa",

@@ -36,3 +36,3 @@ "main": "dist/index.js",

},
"gitHead": "ff49d2332252e7f0e03312e8c9123ed756217807"
"gitHead": "60f164913d022132c8f6a00fc3c4b66c590b2d6e"
}

@@ -20,2 +20,71 @@ import Joi from "joi"

Joi.dateFilter = () => {
return Joi.object({
lt: Joi.alternatives(Joi.date().timestamp("unix"), Joi.date()),
gt: Joi.alternatives(Joi.date().timestamp("unix"), Joi.date()),
gte: Joi.alternatives(Joi.date().timestamp("unix"), Joi.date()),
lte: Joi.alternatives(Joi.date().timestamp("unix"), Joi.date()),
})
}
Joi.orderFilter = () => {
return Joi.object().keys({
id: Joi.string(),
q: Joi.string(),
status: Joi.array()
.items(
Joi.string().valid(
"pending",
"completed",
"archived",
"canceled",
"requires_action"
)
)
.single(),
fulfillment_status: Joi.array()
.items(
Joi.string().valid(
"not_fulfilled",
"fulfilled",
"partially_fulfilled",
"shipped",
"partially_shipped",
"canceled",
"returned",
"partially_returned",
"requires_action"
)
)
.single(),
payment_status: Joi.array()
.items(
Joi.string().valid(
"captured",
"awaiting",
"not_paid",
"refunded",
"partially_refunded",
"canceled",
"requires_action"
)
)
.single(),
display_id: Joi.string(),
cart_id: Joi.string(),
offset: Joi.string(),
limit: Joi.string(),
expand: Joi.string(),
fields: Joi.string(),
customer_id: Joi.string(),
email: Joi.string(),
region_id: Joi.string(),
currency_code: Joi.string(),
tax_rate: Joi.string(),
canceled_at: Joi.dateFilter(),
created_at: Joi.dateFilter(),
updated_at: Joi.dateFilter(),
})
}
export default Joi
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