forked from 0x2620/oxjs
use [].concat, not Ox.merge
This commit is contained in:
parent
36d0162b8b
commit
1c40fb007b
27 changed files with 87 additions and 90 deletions
|
|
@ -88,7 +88,7 @@ Ox.highlightHTML = function(html, str, classname, tags) {
|
|||
position,
|
||||
positions = [];
|
||||
//fixme: default tags should be same as in parseHTML
|
||||
tags = Ox.merge(tags || [], [
|
||||
tags = (tags || []).concat([
|
||||
// inline formatting
|
||||
'b', 'code', 'i', 's', 'sub', 'sup', 'u',
|
||||
// block formatting
|
||||
|
|
@ -401,8 +401,8 @@ Ox.repeat = function(val, num) {
|
|||
var ret;
|
||||
if (Ox.isArray(val)) {
|
||||
ret = [];
|
||||
num >= 1 && Ox.loop(num, function() {
|
||||
ret = Ox.merge(ret, val);
|
||||
Ox.loop(num, function() {
|
||||
ret = ret.concat(val);
|
||||
});
|
||||
} else {
|
||||
ret = num >= 1 ? new Array(num + 1).join(val.toString()) : '';
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue