Skip to content

Commit

Permalink
index.php: move /api/mp.php to functions/mp_latest_recommended.php
Browse files Browse the repository at this point in the history
  • Loading branch information
cowpod committed Oct 31, 2024
1 parent 4e51554 commit c9763b2
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions index.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@
require('functions/interval_range_utils.php');
require('functions/format_number.php');

require('functions/mp_latest_recommended.php');

if (strpos($url, '?') !== false) {
$url = substr($url, 0, strpos($url, "?"));
}
Expand Down Expand Up @@ -800,8 +802,7 @@ function uri($uri) {
<a class="nav-link" href="./dashboard"><em class="fas fa-arrow-left fa-lg"></em> <?php echo $modpack['display_name'] ?></a>
</li>
<?php
$packapi = require('./api/mp.php');
$packdata = json_decode($packapi, true);
$packdata = json_decode(mp_latest_recommended($db), true);

$latest=false;
if ($packdata['latest']!=null) {
Expand Down

0 comments on commit c9763b2

Please sign in to comment.