Skip to content

Commit 0847534

Browse files
committed
Add rollback in case site clone fails
1 parent 32fdfb0 commit 0847534

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

php/EE/RevertableStepProcessor.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,10 @@ public function execute() {
7575
*/
7676
public function rollback() {
7777
while ( $this->execution_index >= 0 ) {
78+
if ( ! array_key_exists( $this->execution_index, $this->steps ) ) {
79+
$this->execution_index--;
80+
continue;
81+
}
7882
$step = $this->steps[ $this->execution_index ];
7983
$context = $step['context'];
8084
try {

0 commit comments

Comments
 (0)