diff options
author | Paul Arthur <paul.arthur@flowerysong.com> | 2013-02-11 16:45:30 -0500 |
---|---|---|
committer | Paul Arthur <paul.arthur@flowerysong.com> | 2013-02-11 17:23:33 -0500 |
commit | 5bc48fd3b2035e11b137b660bf17c6878c0f1a86 (patch) | |
tree | bc60d6e2828df14404434a453f02266592d1eaad | |
parent | 3a8feaeeffe9b96b67ceb49f10295deb088ce4e6 (diff) | |
download | ampache-5bc48fd3b2035e11b137b660bf17c6878c0f1a86.tar.gz ampache-5bc48fd3b2035e11b137b660bf17c6878c0f1a86.tar.bz2 ampache-5bc48fd3b2035e11b137b660bf17c6878c0f1a86.zip |
Fix xml.server.php after changes to session
It was calling the wrong method in Session, which is entirely my fault.
Also, the correct method was broken. Gah.
-rw-r--r-- | lib/class/session.class.php | 2 | ||||
-rw-r--r-- | server/xml.server.php | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/class/session.class.php b/lib/class/session.class.php index a4d3d576..0f6540fc 100644 --- a/lib/class/session.class.php +++ b/lib/class/session.class.php @@ -156,7 +156,7 @@ class Session { * This returns the username associated with a session ID, if any */ public static function username($key) { - return self::_read($key, 'user'); + return self::_read($key, 'username'); } /** diff --git a/server/xml.server.php b/server/xml.server.php index 3d6d804f..31a66458 100644 --- a/server/xml.server.php +++ b/server/xml.server.php @@ -59,7 +59,7 @@ if (!Session::exists('api', $_REQUEST['auth']) AND $_REQUEST['action'] != 'hands $username = ($_REQUEST['action'] == 'handshake' || $_REQUEST['action'] == 'ping') ? $_REQUEST['user'] - : Session::user($_REQUEST['auth']); + : Session::username($_REQUEST['auth']); if (!Access::check_network('init-api', $username, 5)) { debug_event('Access Denied','Unauthorized access attempt to API [' . $_SERVER['REMOTE_ADDR'] . ']', '3'); |