GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

src/util/buffer.js   A
last analyzed

Complexity

Total Complexity 2
Complexity/F 1

Size

Lines of Code 21
Function Count 2

Duplication

Duplicated Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 0
wmc 2
c 0
b 0
f 0
nc 1
mnd 0
bc 2
fnc 2
dl 0
loc 21
rs 10
bpm 1
cpm 1
noi 0
1
export const bufferTop = (
2
    rowHeight, viewableIndex, viewableCount, bufferMultiplier
3
) => {
4
    const spacerCount = Math.max(
5
        viewableIndex - viewableCount * bufferMultiplier,
6
        0
7
    );
8
9
    return spacerCount * rowHeight;
10
};
11
12
export const bufferBottom = (
13
    rowHeight, viewableIndex, viewableCount, bufferMultiplier, totalCount
14
) => {
15
    const spacerCount = Math.max(
16
        totalCount - viewableIndex - viewableCount * (bufferMultiplier + 1),
17
        0
18
    );
19
20
    return spacerCount * rowHeight;
21
};
22