<commit_before><?
class PouetBoxLatestReleased extends PouetBoxCachable {
  var $data;
  var $prods;
  function PouetBoxLatestReleased() {
    parent::__construct();
    $this->uniqueID = "pouetbox_latestreleased";
    $this->title = "latest released prods";

    $this->limit = 5;
  }

  function LoadFromCachedData($data) {
    $this->data = unserialize($data);
  }

  function GetCacheableData() {
    return serialize($this->data);
  }

  function SetParameters($data)
  {
    if (isset($data["limit"])) $this->limit = $data["limit"];
  }

  function LoadFromDB() {
    $s = new BM_Query("prods");
    $s->AddOrder("prods.date DESC,prods.quand DESC");
    $s->SetLimit(POUET_CACHE_MAX);
    $this->data = $s->perform();
    PouetCollectPlatforms($this->data);
  }

  function RenderBody() {
    echo "<ul class='boxlist boxlisttable'>\n";
    $n = 0;
    foreach($this->data as $p) {
      echo "<li>\n";
      echo "<span class='rowprod'>\n";
      echo $p->RenderAsEntry();
      echo "</span>\n";
      if (get_setting("indexwhoaddedprods"))
      {
        echo "<span class='rowuser'>\n";
        echo $p->addeduser->PrintLinkedAvatar();
        echo "</span>\n";
      }
      echo "</li>\n";
      if (++$n == $this->limit) break;
    }
    echo "</ul>\n";
  }
  function RenderFooter() {
    echo "  <div class='foot'><a href='prodlist.php?order=added'>more</a>...</div>\n";
    echo "</div>\n";
  }
};

?><commit_msg>Latest Released link was wrong all along :|<commit_after><?
class PouetBoxLatestReleased extends PouetBoxCachable {
  var $data;
  var $prods;
  function PouetBoxLatestReleased() {
    parent::__construct();
    $this->uniqueID = "pouetbox_latestreleased";
    $this->title = "latest released prods";

    $this->limit = 5;
  }

  function LoadFromCachedData($data) {
    $this->data = unserialize($data);
  }

  function GetCacheableData() {
    return serialize($this->data);
  }

  function SetParameters($data)
  {
    if (isset($data["limit"])) $this->limit = $data["limit"];
  }

  function LoadFromDB() {
    $s = new BM_Query("prods");
    $s->AddOrder("prods.date DESC,prods.quand DESC");
    $s->SetLimit(POUET_CACHE_MAX);
    $this->data = $s->perform();
    PouetCollectPlatforms($this->data);
  }

  function RenderBody() {
    echo "<ul class='boxlist boxlisttable'>\n";
    $n = 0;
    foreach($this->data as $p) {
      echo "<li>\n";
      echo "<span class='rowprod'>\n";
      echo $p->RenderAsEntry();
      echo "</span>\n";
      if (get_setting("indexwhoaddedprods"))
      {
        echo "<span class='rowuser'>\n";
        echo $p->addeduser->PrintLinkedAvatar();
        echo "</span>\n";
      }
      echo "</li>\n";
      if (++$n == $this->limit) break;
    }
    echo "</ul>\n";
  }
  function RenderFooter() {
    echo "  <div class='foot'><a href='prodlist.php?order=release'>more</a>...</div>\n";
    echo "</div>\n";
  }
};

?>
{'fraction_non_alphanumeric': 0.19363762102351315, 'fraction_numerical': 0.0013831258644536654, 'mean_word_length': 3.0180555555555557, 'pattern_counts': {'":': 0, '<': 31, '<?xml version=': 0, '>': 63, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7380157', 'n_tokens_mistral': 1037, 'n_tokens_neox': 1027, 'n_words': 189}