Преглед изворни кода

:recycle: altering the p2p registration order to flip-flop shorts_to_episodes and guides_to_episodes

tags/0.9.0
J пре 4 година
родитељ
комит
61b8fa0f06
1 измењених фајлова са 6 додато и 4 уклоњено
  1. 6
    4
      plugins/cia-post-types/includes/p2p-mappings.php

+ 6
- 4
plugins/cia-post-types/includes/p2p-mappings.php Прегледај датотеку

@@ -32,21 +32,23 @@ function all_connection_types() {
32 32
         'event',
33 33
         'exhibition',
34 34
         'post',
35
+        'technique',
35 36
         'guide',
36 37
         'short',
37
-        'technique',
38 38
     ];
39 39
 
40 40
     // Kick-off by assigning to artist
41 41
     $artist = array_shift($connection_stack);
42 42
     register_connections_for($artist, $connection_stack);
43
+
44
+    /** Pop the end for now... */ 
45
+    $short = array_pop($connection_stack);
46
+    $guide = array_pop($connection_stack);
47
+    
43 48
     $episode = array_shift($connection_stack);
44 49
     register_connections_for($episode, $connection_stack);
45 50
     
46
-    /** Pop the end for now... */ 
47 51
     $technique = array_pop($connection_stack);
48
-    $short = array_pop($connection_stack);
49
-    $guide = array_pop($connection_stack);
50 52
     
51 53
     // Remaining: ['event', 'exhibition', 'post']
52 54
     $event = array_shift($connection_stack);

Loading…
Откажи
Сачувај