Skip to content

Commit

Permalink
stylistic fix
Browse files Browse the repository at this point in the history
  • Loading branch information
zloirock committed Oct 23, 2021
1 parent 593f257 commit c901ef8
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions packages/core-js/internals/array-unique-by.js
Expand Up @@ -20,11 +20,10 @@ module.exports = function uniqueBy(resolver) {
var length = lengthOfArrayLike(that);
var result = arraySpeciesCreate(that, 0);
var map = new Map();
var resolverFunction, index, item, key;
if (resolver != null) resolverFunction = aCallable(resolver);
else resolverFunction = function (value) {
var resolverFunction = resolver != null ? aCallable(resolver) : function (value) {
return value;
};
var index, item, key;
for (index = 0; index < length; index++) {
item = that[index];
key = resolverFunction(item);
Expand Down

0 comments on commit c901ef8

Please sign in to comment.