Skip to content

Commit

Permalink
Userviews: fix to use new replicas design
Browse files Browse the repository at this point in the history
  • Loading branch information
MusikAnimal committed Jan 5, 2021
1 parent 7a5d444 commit aab71ca
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion public_html/userviews/api.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
$db = $site_map[$project] . '_p';

// connect to database
$client = new mysqli( DB_HOST, DB_USER, DB_PASSWORD, $db, DB_PORT );
$host = str_replace( '*', $site_map[$project], DB_HOST ); // For production replicas
$client = new mysqli( $host, DB_USER, DB_PASSWORD, $db, DB_PORT );

// quit if something went wrong
if (mysqli_connect_errno()) {
Expand Down

0 comments on commit aab71ca

Please sign in to comment.