不要怂,就是干,撸起袖子干!

Commit 1c96744f by Jan Aagaard Meier

Merge pull request #2746 from x-warrior/master

Resolving multiple hasMany cascades which weren't working in some cases
2 parents 8ea99e8a 0bbf8de9
...@@ -604,7 +604,12 @@ module.exports = (function() { ...@@ -604,7 +604,12 @@ module.exports = (function() {
dao[cascades[i]]().success(function(tasks) { dao[cascades[i]]().success(function(tasks) {
if (tasks === null || tasks.length < 1) { if (tasks === null || tasks.length < 1) {
if (i >= cascades.length) {
return resolve(); return resolve();
} else {
tick++;
return iterate(null, tick);
}
} }
tasks = Array.isArray(tasks) ? tasks : [tasks]; tasks = Array.isArray(tasks) ? tasks : [tasks];
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!