r78365 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r78364‎ | r78365 | r78366 >
Date:11:09, 14 December 2010
Author:catrope
Status:ok (Comments)
Tags:
Comment:
Followup r78104: set the cookie unconditionally, so its expiry is renewed every time sessionId() is called
Modified paths:
  • /trunk/phase3/resources/mediawiki/mediawiki.js (modified) (history)

Diff [purge]

Index: trunk/phase3/resources/mediawiki/mediawiki.js
@@ -342,8 +342,9 @@
343343 var sessionId = $.cookie( 'mediaWiki.user.sessionId' );
344344 if ( typeof sessionId == 'undefined' || sessionId == null ) {
345345 sessionId = generateSessionId();
346 - $.cookie( 'mediaWiki.user.sessionId', sessionId, { 'expires': 30, 'path': '/' } );
347346 }
 347+ // Set cookie if not set, or renew it if already set
 348+ $.cookie( 'mediaWiki.user.sessionId', sessionId, { 'expires': 30, 'path': '/' } );
348349 return sessionId;
349350 };
350351 }

Follow-up revisions

RevisionCommit summaryAuthorDate
r830371.17wmf1: Merge revs to mediawiki.js required by ArticleFeedback: r78104, r78...catrope19:23, 1 March 2011
r85080MFT r78108, r78179, r78344, r78347, r78350, r78365, r78380, r78425, r78539, r...demon19:09, 31 March 2011

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r78104Added name and sessionId methods to user object - now anonymous users have an...tparscal23:18, 8 December 2010

Comments

#Comment by Trevor Parscal (WMF) (talk | contribs)   18:53, 14 December 2010

Well done - this is an excellent change!

Status & tagging log