Skip to content

Commit 4de4cd1

Browse files
committed
modify the compile function fix the case where no 'par' exist
or 'par' and 'seq' both exist
1 parent 554ec2d commit 4de4cd1

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

nathansununiversity_01.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,7 @@ var compile = function (expr) {
241241
// your code here
242242
(function(expr) {
243243
if (expr.tag === 'note') {
244-
expr.start = ref;
244+
expr.start = time || ref;
245245
result.push(expr);
246246

247247
time += expr.dur;

nathansununiversity_02.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ var compile = function (expr) {
1010
// your code here
1111
(function(expr) {
1212
if (expr.tag === 'note') {
13-
expr.start = ref;
13+
expr.start = time || ref;
1414
result.push(expr);
1515

1616
time += expr.dur;

0 commit comments

Comments
 (0)