Skip to content

Commit 1db0ee1

Browse files
committed
[fixed] remove es2015 from v1 branch
closes #375
1 parent c8fbae4 commit 1db0ee1

File tree

1 file changed

+17
-17
lines changed

1 file changed

+17
-17
lines changed

lib/helpers/refCount.js

+17-17
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,19 @@
1-
const modals = [];
1+
var modals = [];
22

3-
export function add (element) {
4-
if (modals.indexOf(element) === -1) {
5-
modals.push(element);
3+
module.exports = {
4+
add (element) {
5+
if (modals.indexOf(element) === -1) {
6+
modals.push(element);
7+
}
8+
},
9+
remove (element) {
10+
const index = modals.indexOf(element);
11+
if (index === -1) {
12+
return;
13+
}
14+
modals.splice(index, 1);
15+
},
16+
count () {
17+
return modals.length;
618
}
7-
}
8-
9-
export function remove (element) {
10-
const index = modals.indexOf(element);
11-
if (index === -1) {
12-
return;
13-
}
14-
modals.splice(index, 1);
15-
}
16-
17-
export function count () {
18-
return modals.length;
19-
}
19+
};

0 commit comments

Comments
 (0)