File tree 1 file changed +6
-6
lines changed
packages/playground/data-liberation/src/import
1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -205,7 +205,10 @@ public function next_step() {
205
205
$ this ->next_stage = self ::STAGE_TOPOLOGICAL_SORT ;
206
206
return false ;
207
207
case self ::STAGE_TOPOLOGICAL_SORT :
208
- $ this ->next_topological_sort_step ();
208
+ if ( true === $ this ->topological_sort_next_entity () ) {
209
+ return true ;
210
+ }
211
+ $ this ->stage = self ::STAGE_FRONTLOAD_ASSETS ;
209
212
return true ;
210
213
case self ::STAGE_FRONTLOAD_ASSETS :
211
214
if ( true === $ this ->frontload_next_entity () ) {
@@ -373,20 +376,17 @@ private function frontloading_advance_reentrancy_cursor() {
373
376
}
374
377
}
375
378
376
- private function next_topological_sort_step () {
379
+ private function topological_sort_next_entity () {
377
380
if ( null === $ this ->entity_iterator ) {
378
- $ this ->downloader = new WP_Attachment_Downloader ( $ this ->options );
379
381
$ this ->entity_iterator = $ this ->create_entity_iterator ();
380
382
$ this ->topological_sorter = new WP_Topological_Sorter ();
381
383
}
382
384
383
385
if ( ! $ this ->entity_iterator ->valid () ) {
384
- $ this ->stage = self ::STAGE_FRONTLOAD_ASSETS ;
385
386
$ this ->topological_sorter = null ;
386
- $ this ->downloader = null ;
387
387
$ this ->entity_iterator = null ;
388
388
$ this ->resume_at_entity = null ;
389
- return ;
389
+ return false ;
390
390
}
391
391
392
392
// $cursor = $this->entity_iterator->get_reentrancy_cursor();
You can’t perform that action at this time.
0 commit comments