utiller 1.0.300 → 1.0.301
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/lib/utiller/index.js
CHANGED
|
@@ -159,6 +159,9 @@ var Utiller = /*#__PURE__*/function () {
|
|
|
159
159
|
(0, _defineProperty2["default"])(this, "findLowestValue", function (items) {
|
|
160
160
|
var key = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : "price";
|
|
161
161
|
// 提取價格並找出最小值
|
|
162
|
+
items = _lodash["default"].filter(function (each) {
|
|
163
|
+
return each && each.price > 0;
|
|
164
|
+
});
|
|
162
165
|
var minPrice = _lodash["default"].minBy(items, key)[key];
|
|
163
166
|
|
|
164
167
|
// 確保回傳的最低價為 integer 型態
|
package/package.json
CHANGED