Title: [292936] trunk/Websites/webkit.org
Revision
292936
Author
[email protected]
Date
2022-04-15 18:16:56 -0700 (Fri, 15 Apr 2022)

Log Message

[webkit.org] Remove leading r from archive revisions (Follow-up fix)
https://bugs.webkit.org/show_bug.cgi?id=239322
<rdar://problem/91735590>

Reviewed by Alexey Proskuryakov.

* Websites/webkit.org/wp-content/themes/webkit/build-archives.php:
Identifiers are strings, not integers. Use new v3 endpoint.

Canonical link: https://commits.webkit.org/249700@main

Modified Paths

Diff

Modified: trunk/Websites/webkit.org/ChangeLog (292935 => 292936)


--- trunk/Websites/webkit.org/ChangeLog	2022-04-16 01:16:01 UTC (rev 292935)
+++ trunk/Websites/webkit.org/ChangeLog	2022-04-16 01:16:56 UTC (rev 292936)
@@ -1,3 +1,14 @@
+2022-04-15  Jonathan Bedard  <[email protected]>
+
+        [webkit.org] Remove leading r from archive revisions (Follow-up fix)
+        https://bugs.webkit.org/show_bug.cgi?id=239322
+        <rdar://problem/91735590>
+
+        Reviewed by Alexey Proskuryakov.
+
+        * Websites/webkit.org/wp-content/themes/webkit/build-archives.php:
+        Identifiers are strings, not integers. Use new v3 endpoint.
+
 2022-04-13  Jonathan Bedard  <[email protected]>
 
         [webkit.org] Remove leading r from archive revisions

Modified: trunk/Websites/webkit.org/wp-content/themes/webkit/build-archives.php (292935 => 292936)


--- trunk/Websites/webkit.org/wp-content/themes/webkit/build-archives.php	2022-04-16 01:16:01 UTC (rev 292935)
+++ trunk/Websites/webkit.org/wp-content/themes/webkit/build-archives.php	2022-04-16 01:16:56 UTC (rev 292936)
@@ -12,7 +12,6 @@
     public static $platforms = array(
         'mac-monterey-x86_64%20arm64'     => 'Monterey',
         'mac-bigsur-x86_64%20arm64'     => 'Big Sur',
-        'mac-catalina-x86_64'     => 'Catalina',
     );
 
     public static function object() {
@@ -22,7 +21,7 @@
     }
 
     private function call ($endpoint, $params = array()) {
-        $url = "" 'https://q1tzqfy48e.execute-api.us-west-2.amazonaws.com/v2_2/' . $endpoint);
+        $url = "" 'https://q1tzqfy48e.execute-api.us-west-2.amazonaws.com/v3/' . $endpoint);
         $api = wp_remote_get($url);
         $response = wp_remote_retrieve_body($api);
 
@@ -44,10 +43,10 @@
         $latest[$platform_key] = array();
 
         foreach ($data->Items as &$entry) {
-            $revision = new stdClass();
-            $revision->url = ""
-            $revision->creationTime = $entry->creationTime->N;
-            $latest[$platform_key][$entry->revision->N] = $revision;
+            $change = new stdClass();
+            $change->url = ""
+            $change->creationTime = $entry->creationTime->N;
+            $latest[$platform_key][$entry->identifier->S] = $change;
         }
 
         set_transient($cachekey, serialize($latest), 600); // expire cache every 10 minutes
@@ -131,9 +130,9 @@
 
     $lists = '';
     ob_start();
-    foreach ($archives as $platform => $revisions):
+    foreach ($archives as $platform => $changes):
 
-        if (empty($revisions)) {
+        if (empty($changes)) {
             echo '<div class="platform-items ' . esc_attr($platform) . '">' . $error_markup . '</div>';
             continue;
         }
@@ -140,9 +139,9 @@
     ?>
 
     <ul class="platform-items <?php echo esc_attr($platform); ?>">
-        <?php foreach ($revisions as $revision => $entry): ?>
+        <?php foreach ($changes as $change => $entry): ?>
         <li>
-            <h6><a href="" echo esc_url($entry->url); ?>"><?php echo $revision; ?></a></h6>
+            <h6><a href="" echo esc_url($entry->url); ?>"><?php echo $change; ?></a></h6>
             <span class="date"><?php echo intval($entry->creationTime) * 1000; ?></span>
         </li>
         <?php endforeach?>
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to