added try catch to rename in db.php