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/reducers/actionHelpers/grid.js   A
last analyzed

Complexity

Total Complexity 7
Complexity/F 1.4

Size

Lines of Code 59
Function Count 5

Duplication

Duplicated Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 0
wmc 7
nc 1
mnd 1
bc 5
fnc 5
dl 0
loc 59
rs 10
bpm 1
cpm 1.4
noi 0
c 0
b 0
f 0

1 Function

Rating   Name   Duplication   Size   Complexity  
A grid.js ➔ ??? 0 8 1
1
import { generateLastUpdate } from './../../util/lastUpdate';
2
3
import { Grid } from './../../records';
4
5
import localStorageManager from './../../components/core/LocalStorageManager'; // eslint-disable-line
6
import getUpdatedRecord from './../../util/getUpdatedRecord';
7
8
const debouncedColumnSetter = localStorageManager.debouncedSetStateItem();
9
10
export const hideHeader = (state, { stateKey, headerHidden }) =>
11
    getUpdatedRecord(
12
        state, stateKey, {
13
            headerHidden: headerHidden,
14
            lastUpdate: generateLastUpdate()
15
        },
16
        Grid
17
    );
18
19
export const setColumns = (state, { columns, stateKey, stateful }) => {
20
    if (stateful) {
21
        setColumnsInStorage({
22
            stateKey: stateKey,
23
            columns: columns
24
        });
25
    }
26
27
    return getUpdatedRecord(state, stateKey, {
28
        columns: columns,
29
        lastUpdate: generateLastUpdate()
30
    }, Grid);
31
};
32
33
export const setSortDirection = (state, { stateKey, columns }) =>
34
    getUpdatedRecord(state, stateKey, {
35
        columns: columns,
36
        lastUpdate: generateLastUpdate()
37
    }, Grid);
38
39
export const resizeColumns = (state, { stateful, stateKey, columns }) => {
40
    if (stateful) {
41
        setColumnsInStorage({
42
            stateKey: stateKey,
43
            columns: columns
44
        });
45
    }
46
47
    return getUpdatedRecord(state, stateKey, {
48
        columns: columns,
49
        lastUpdate: generateLastUpdate()
50
    }, Grid);
51
};
52
53
export const setColumnsInStorage = ({ columns, stateKey }) => {
54
    debouncedColumnSetter({
55
        stateKey: stateKey,
56
        property: 'columns',
57
        value: columns
58
    });
59
};
60