Postgres: make sure ar_len is added when updating, alpha stuff in updaters.inc
[lhc/web/wiklou.git] / includes / LoadBalancer.php
index f256b7e..d3d072e 100644 (file)
@@ -502,8 +502,7 @@ class LoadBalancer {
         * Save master pos to the session and to memcached, if the session exists
         */
        function saveMasterPos() {
-               global $wgSessionStarted;
-               if ( $wgSessionStarted && count( $this->mServers ) > 1 ) {
+               if ( session_id() != '' && count( $this->mServers ) > 1 ) {
                        # If this entire request was served from a slave without opening a connection to the
                        # master (however unlikely that may be), then we can fetch the position from the slave.
                        if ( empty( $this->mConnections[0] ) ) {