Skip to content

Commit 07e22ab

Browse files
committed
Fixed hash routing hanging for malformed routes.
1 parent 7d9dc74 commit 07e22ab

2 files changed

Lines changed: 5 additions & 5 deletions

File tree

aris.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*!
2-
* Aris JavaScript Library v1.0.8
2+
* Aris JavaScript Library v1.0.10
33
* @author Benjamin Kang Yue Sheng
44
* MIT license
55
*
@@ -685,7 +685,7 @@
685685

686686
if (!n) return '';
687687

688-
if (n && (isArray(context[0]) || context[0] === null || !tag.match(htmlTagRe))) {
688+
if (n && (isArray(context[0]) || isUndefinedOrNull(context[0]) || !tag.match(htmlTagRe))) {
689689
for (r = '', i = 0; i < n; i++) {
690690
if (isFunction(context[i+1])) {
691691
mn = mapNext(context, i);
@@ -699,7 +699,7 @@
699699
return r;
700700
}
701701

702-
for (i = 1; i < n; i++) if (context[i] !== null) {
702+
for (i = 1; i < n; i++) if (!isUndefinedOrNull(context[i])) {
703703
obj = context[i];
704704
if (isArray(obj)) {
705705
if (isFunction(context[i+1])) {
@@ -720,7 +720,7 @@
720720
css[mSub[1]] = mSub[2];
721721
v = css;
722722
}
723-
if (obj.hasOwnProperty(k) && v !== null) {
723+
if (obj.hasOwnProperty(k) && !isUndefinedOrNull(v)) {
724724
if (isObject(v)) {
725725
if (!attrs.hasOwnProperty(k) || !isObject(attrs[k]))
726726
attrs[k] = {};

aris.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)