]> git.wh0rd.org - tt-rss.git/blobdiff - update.php
code cleanup, test for db_escape() crazyness in DB sanity check
[tt-rss.git] / update.php
index e15e3be00b1f2558694d8c1c75a322f79562a839..76e3088567128eb19375742248f1cc347515b354 100644 (file)
@@ -9,15 +9,8 @@
        require_once "db.php";
        
        $link = db_connect(DB_HOST, DB_USER, DB_PASS, DB_NAME); 
-       
-       if (DB_TYPE == "pgsql") {
-               pg_query($link, "set client_encoding = 'utf-8'");
-               pg_set_client_encoding("UNICODE");
-       } else {
-               db_query($link, "SET NAMES utf8");
-               db_query($link, "SET CHARACTER SET utf8");
-       }
 
+       init_connection($link); 
        login_sequence($link);
        
        $owner_uid = $_SESSION["uid"];
@@ -106,7 +99,7 @@ function confirmOP() {
        }
        
        if (!$op) {
-               print_warning("Please backup your database before proceeding.");
+               print_warning(__("Please backup your database before proceeding."));
        
                print "<p>" . T_sprintf("Your Tiny Tiny RSS database needs update to the latest version (<b>%d</b> to <b>%d</b>).", $version, $latest_version) . "</p>";