r80370 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r80369‎ | r80370 | r80371 >
Date:00:50, 15 January 2011
Author:kaldari
Status:ok
Tags:
Comment:
adding basic getCookieDomain function
Modified paths:
  • /trunk/extensions/CentralAuth/CentralAuthUser.php (modified) (history)

Diff [purge]

Index: trunk/extensions/CentralAuth/CentralAuthUser.php
@@ -1805,6 +1805,16 @@
18061806
18071807 self::deleteSession();
18081808 }
 1809+
 1810+ /**
 1811+ * Get the domain parameter for setting a global cookie.
 1812+ * This allows other extensions to easily set global cookies without directly relying on
 1813+ * $wgCentralAuthCookieDomain (in case CentralAuth's implementation changes at some point).
 1814+ */
 1815+ static function getCookieDomain() {
 1816+ global $wgCentralAuthCookieDomain;
 1817+ return $wgCentralAuthCookieDomain;
 1818+ }
18091819
18101820 /**
18111821 * Check a global auth token against the one we know of in the database.

Follow-up revisions

RevisionCommit summaryAuthorDate
r80607Picking up r80370tomasz00:38, 20 January 2011
r82234MFT r80370demon11:57, 16 February 2011

Status & tagging log