view/frontend/web/js/buy-now-list.js   A
last analyzed

Complexity

Total Complexity 2
Complexity/F 1

Size

Lines of Code 12
Function Count 2

Duplication

Duplicated Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 9
c 0
b 0
f 0
dl 0
loc 12
rs 10
wmc 2
mnd 0
bc 0
fnc 2
bpm 0
cpm 1
noi 0
1
define([
2
    'jquery'
3
], function ($) {
4
    'use strict';
5
6
    return function (config, element) {
7
        var addToCardForm = $(element).parent().parent().find('form');
8
        var buyNowBtn = $(element).html();
9
        addToCardForm.append(buyNowBtn);
10
        $(element).html('');
11
    }
12
});
13