Skip to content

Commit e6a3a34

Browse files
committed
fix(badwordsused): fix returns when providing empty string
1 parent f41a753 commit e6a3a34

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ var LeoProfanity = {
195195
* @returns {Array.string}
196196
*/
197197
badWordsUsed: function (str) {
198-
if (!str) return '';
198+
if (!str) return [];
199199
return this.proceed(str, '*')[1];
200200
},
201201

0 commit comments

Comments
 (0)