Skip to content
Snippets Groups Projects
Commit 66665e85 authored by Thomas Truffin's avatar Thomas Truffin
Browse files

destructuring

parent dd0e8e82
No related branches found
No related tags found
No related merge requests found
......@@ -53,7 +53,7 @@ function croissantSort(a, b) {
function unCroissantSort(a, b) {
return b.price_small - a.price_small;
}
function doubleI(a) {
let test = a.name.toLowerCase().split("i").length - 1;
function doubleI({ name }) {
let test = name.toLowerCase().split("i").length - 1;
return test === 2;
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment