Completed
Push — master ( 7b5fbf...d41ae8 )
by greg
03:18
created

src/cli/cms/templates/handlebars/lowercase.js   A

Complexity

Total Complexity 3
Complexity/F 3

Size

Lines of Code 7
Function Count 1

Duplication

Duplicated Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 0
wmc 3
nc 1
mnd 1
bc 3
fnc 1
dl 0
loc 7
rs 10
bpm 3
cpm 3
noi 0
c 1
b 0
f 0
1
/**
2
 * Handlebars helper, lowercase the str
3
 */
4
export default function lowercase(str) {
5
  if(typeof str === 'undefined' || str === null){
6
    return '';
7
  } else {
8
    return str.toLowerCase();
9
  }
10
}