Commit f7787f50 f7787f50ea8042e245de75b4e96eac780efc6f57 by Nicolas Perriault

removed the obligation to add an empty step if start() would just suffice

1 parent d8d08333
...@@ -703,11 +703,9 @@ ...@@ -703,11 +703,9 @@
703 this.options.onPageInitialized.call(this, this.page); 703 this.options.onPageInitialized.call(this, this.page);
704 } 704 }
705 if (isType(location, "string") && location.length > 0) { 705 if (isType(location, "string") && location.length > 0) {
706 if (isType(then, "function")) { 706 return this.thenOpen(location, isType(then, "function") ? then : this.createStep(function(self) {
707 return this.open(location).then(then); 707 self.log("start page is loaded", "debug");
708 } else { 708 }));
709 return this.open(location);
710 }
711 } 709 }
712 return this; 710 return this;
713 }, 711 },
......