Sign in
apache
/
cordova-js
/
refs/heads/cb-4.2.3-node-modules-for-coho-only
/
.
/
node_modules
/
underscore.string
/
count.js
blob: 2207d709b596e47bd8d350470cd261bf86ec1070 [
file
] [
log
] [
blame
]
var
makeString
=
require
(
'./helper/makeString'
);
module
.
exports
=
function
(
str
,
substr
)
{
str
=
makeString
(
str
);
substr
=
makeString
(
substr
);
if
(
str
.
length
===
0
||
substr
.
length
===
0
)
return
0
;
return
str
.
split
(
substr
).
length
-
1
;
};