mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-09 10:27:49 +00:00
Remove arrayReduce from createCompounder.
This commit is contained in:
@@ -1,4 +1,3 @@
|
|||||||
import arrayReduce from './arrayReduce.js'
|
|
||||||
import words from '../words.js'
|
import words from '../words.js'
|
||||||
|
|
||||||
/** Used to match apostrophes. */
|
/** Used to match apostrophes. */
|
||||||
@@ -13,7 +12,7 @@ const reApos = /['\u2019]/g
|
|||||||
*/
|
*/
|
||||||
function createCompounder(callback) {
|
function createCompounder(callback) {
|
||||||
return (string) => (
|
return (string) => (
|
||||||
arrayReduce(words(`${ string }`.replace(reApos, '')), callback, '')
|
words(`${ string }`.replace(reApos, '')).reduce(callback, '')
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user