removing smarty - part XIV (only one more..)

- added some forgotten account-srings
- fixed an error handling ItemFilter /w upgradeItems + markdown appearing in tooltips
- relaxed session-regeneration (only regenerates on status changes (signin/-out)), fixes losing the session, when opening multiple tabs at once
- striped smarty from profiler (only cleanups remaining)
- moved profiler-ajax to AjaxHandler
- created a (dummy, for now) ProfileClass to handle Chars and Profiles
This commit is contained in:
Sarjuuk
2014-07-16 21:48:07 +02:00
parent a82aa2b6ae
commit 0af712a8ff
27 changed files with 1103 additions and 848 deletions

View File

@@ -62,6 +62,11 @@ class DB
return isset(self::$connectionCache[$idx]);
}
public static function isConnectable($idx)
{
return isset(self::$optionsCache[$idx]);
}
private static function safeGetDB($idx)
{
if(!self::isConnected($idx))
@@ -74,12 +79,12 @@ class DB
* @static
* @return DbSimple_Mysql
*/
public static function Characters($realm_id)
public static function Characters($realm)
{
if (!isset(self::$optionsCache[DB_CHARACTERS+$realm_id]))
die('Connection info not found for live database of realm #'.$realm_id.'. Aborted.');
if (!isset(self::$optionsCache[DB_CHARACTERS.$realm]))
die('Connection info not found for live database of realm #'.$realm.'. Aborted.');
return self::safeGetDB(DB_CHARACTERS+$realm_id);
return self::safeGetDB(DB_CHARACTERS.$realm);
}
/**