Socket
Socket
Sign inDemoInstall

promise.prototype.finally

Package Overview
Dependencies
Maintainers
2
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

promise.prototype.finally - npm Package Compare versions

Comparing version 3.1.5 to 3.1.7

13

CHANGELOG.md

@@ -8,2 +8,15 @@ # Changelog

## [v3.1.7](https://github.com/es-shims/Promise.prototype.finally/compare/v3.1.6...v3.1.7) - 2023-09-13
### Commits
- [Deps] update `define-properties`, `set-function-name` [`01d3f17`](https://github.com/es-shims/Promise.prototype.finally/commit/01d3f17514abb9da154890c28e317bd3b3ccddfd)
## [v3.1.6](https://github.com/es-shims/Promise.prototype.finally/compare/v3.1.5...v3.1.6) - 2023-09-13
### Commits
- [Refactor] use `set-function-name` [`903d207`](https://github.com/es-shims/Promise.prototype.finally/commit/903d2071f0fc8391ce69fa249915067d57a59332)
- [actions] update checkout action [`594ef8e`](https://github.com/es-shims/Promise.prototype.finally/commit/594ef8ef4cb71189eb867cedeb6b201c7b2e27c2)
## [v3.1.5](https://github.com/es-shims/Promise.prototype.finally/compare/v3.1.4...v3.1.5) - 2023-08-30

@@ -10,0 +23,0 @@

32

implementation.js

@@ -7,2 +7,7 @@ 'use strict';

var GetIntrinsic = require('get-intrinsic');
var $TypeError = GetIntrinsic('%TypeError%');
var PromiseResolve = require('es-abstract/2023/PromiseResolve');
var IsCallable = require('es-abstract/2023/IsCallable');

@@ -12,7 +17,3 @@ var SpeciesConstructor = require('es-abstract/2023/SpeciesConstructor');

var promiseResolve = function PromiseResolve(C, value) {
return new C(function (resolve) {
resolve(value);
});
};
var setFunctionName = require('set-function-name');

@@ -24,3 +25,3 @@ var OriginalPromise = Promise;

var result = onFinally();
var promise = promiseResolve(C, result);
var promise = PromiseResolve(C, result);
var valueThunk = function () {

@@ -36,3 +37,3 @@ return value;

var result = onFinally();
var promise = promiseResolve(C, result);
var promise = PromiseResolve(C, result);
var thrower = function () {

@@ -45,9 +46,9 @@ throw reason;

var promiseFinally = function finally_(onFinally) {
/* eslint no-invalid-this: 0 */
/* eslint no-invalid-this: 0 */
module.exports = setFunctionName(function finally_(onFinally) {
var promise = this;
if (Type(promise) !== 'Object') {
throw new TypeError('receiver is not an Object');
throw new $TypeError('receiver is not an Object');
}

@@ -65,11 +66,2 @@

return promise.then(thenFinally, catchFinally);
};
if (Object.getOwnPropertyDescriptor) {
var descriptor = Object.getOwnPropertyDescriptor(promiseFinally, 'name');
if (descriptor && descriptor.configurable) {
Object.defineProperty(promiseFinally, 'name', { configurable: true, value: 'finally' });
}
}
module.exports = promiseFinally;
}, 'finally', true);
{
"name": "promise.prototype.finally",
"version": "3.1.5",
"version": "3.1.7",
"author": "Jordan Harband <ljharb@gmail.com>",

@@ -54,4 +54,6 @@ "funding": {

"call-bind": "^1.0.2",
"define-properties": "^1.2.0",
"es-abstract": "^1.22.1"
"define-properties": "^1.2.1",
"es-abstract": "^1.22.1",
"get-intrinsic": "^1.2.1",
"set-function-name": "^2.0.1"
},

@@ -58,0 +60,0 @@ "devDependencies": {

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