Commit graph

39742 commits

Author SHA1 Message Date
Sam Reed
24d9a9f179 Revert r105834, WMF locally after fixing PHPUnit 2011-12-11 23:29:06 +00:00
Sam Reed
49d471c67a Mark testPurgeMainPage broken after r105828 and r105833
PhpUnit is more than broken locally (and phpunit.de is down)
2011-12-11 22:39:48 +00:00
Sam Reed
82ee95eb92 Attempt to fix tests broken by r105828
Test wanted in a specific order, now just look up wanted array key from title row

Untested as my phpunit tests seem to be b0rked locally :(
2011-12-11 21:49:05 +00:00
Robin Pepermans
990b93f45e Slight correction to Veps autonym per Wikipedia article and https://meta.wikimedia.org/wiki/Requests_for_new_languages/Wikipedia_Veps_2 (and Google search confirms) 2011-12-11 21:13:18 +00:00
Sam Reed
76762a26b9 Make ApiQueryBase::addTitleInfo() add the pageid also 2011-12-11 21:07:39 +00:00
Sam Reed
35e229c627 More documentation updates as I've been going around 2011-12-11 20:57:57 +00:00
Sam Reed
d1e77338a6 * (bug 32495) API should allow purge by pageids.
ApiPageSet isn't really designed for non query usage, but a little hacking and it can be made to work in the ApiPageSet mould. Allows us to use titles, pageids and revids, without the work of validating them and such ourselves

Same caveat that you can't use a mix of them in one request - tough!
2011-12-11 20:43:42 +00:00
Sam Reed
7ea2f68c3a Followup r105823, make it protected 2011-12-11 20:41:23 +00:00
Raimond Spekking
d6391042ad Localisation updates for core and extension messages from translatewiki.net 2011-12-11 20:35:30 +00:00
Sam Reed
16f4c5fe93 Trailing full stops 2011-12-11 20:34:36 +00:00
Sam Reed
b8d83ec568 Adding a getDB function to ApiBase...
Not all subclasses will need/want it. It does however make it easier to pretend non ApiQuery derivatives actually are...
2011-12-11 20:32:37 +00:00
Daniel Friesen
c6a11daac9 Follow up r105821, as usual, commit the files I forgot to svn add 2011-12-11 19:49:16 +00:00
Daniel Friesen
856310a705 Follow up r102210:
- Update maintenance/dev/ to install php inside ~/.mediawiki/php instead of ~/.mwphp
- Tweak README a bit
- Move the router.php into an includes along with two helper .sh files to cut out some of the repetition
2011-12-11 19:45:15 +00:00
Sam Reed
c8102513e5 * (bug 32414) Empty page get a empty bytes attribute in Export/Dump
Pushing the values through intval seems enough, null -> 0


reedy@fenari:/home/wikipedia/common$ mwscript eval.php dewiki
> $var = null;

> var_dump( intval( $var ) );
int(0)

> var_dump($var );
NULL
2011-12-11 19:01:11 +00:00
Sam Reed
a9702c53af Fix use of undefined $file
Reduce code duplication in Dump7ZipOutput
2011-12-11 18:51:44 +00:00
Daniel Friesen
c5337f8522 Introduce a Language::getHtmlLang method which returns the Bcp47 formatted language code and update code around core to output lang tags using this method instead of getCode so that we properly output things like lang="en-CA" instead of lang="en-ca" 2011-12-11 18:46:18 +00:00
Sam Reed
9457d80c3f * (bug 32415) Empty page get no size attribute in API output 2011-12-11 18:39:31 +00:00
Daniel Friesen
57c8fe18c7 Update wfArrayToCGI and wfCgiToArray:
- 'foo' => '' now outputs "&foo=" instead of the key being omitted
- 'foo' => null and 'foo' => false now omit the key instead of outputting "&foo="
- Added a test to make sure that 'foo' => true outputs "&foo=1"
- Fixed a php notice caused when passing a =value-less bit like "&qwerty" to wfCgiToArray by treating it like php and extracting it as 'qwerty' => ''
- Updated tests
2011-12-11 18:25:23 +00:00
Max Semenik
e159355c7f Added 1.18 schema to tests, comment 2011-12-11 16:56:37 +00:00
Sam Reed
a9a51eda95 Fix double pasting from r105803 2011-12-11 16:37:20 +00:00
Sam Reed
8f1abf5c90 * (bug 31759) Undefined property notice in querypages API 2011-12-11 16:35:50 +00:00
Alexandre Emsenhuber
2acc76365c Fix documentation of Title::userCan() and Title::quickUserCan() and added line breaks in Title::getUserPermissionsErrors()'s one 2011-12-11 16:04:53 +00:00
Sam Reed
b5f11fa813 * (bug 32960) remove EmailAuthenticationTimestamp from database when a
email address is removed

In Preferences::trySetUserEmail no point trying to reset the users email if it's the same

Same for User::setEmail

After setting the email though, invalidate email auth tokens
2011-12-11 15:31:17 +00:00
Alexandre Emsenhuber
68ca2fe2fd Group related functions 2011-12-11 14:48:45 +00:00
Alexandre Emsenhuber
b4a0314342 Per Platonides, fix for r100445: make sure user's language is English so that it doesn't break test 2011-12-11 13:54:44 +00:00
Alexandre Emsenhuber
399b120152 Follow-up r105790: make tests work again 2011-12-11 13:29:21 +00:00
Derk-Jan Hartman
c79fe66b82 Remove useless local var decl. 2011-12-11 12:26:28 +00:00
Alexandre Emsenhuber
87ebe89bed Moved view count from WikiPage to Title; avoids an extra DB query when showing the view count in SkinTemplate::outputPage() (since it's not the same WikiPage object) 2011-12-11 11:30:11 +00:00
Alexandre Emsenhuber
55ec0e84aa Use ParserOptions::newFromContext() instead of 'new ParserOptions' to use the local context and not $wgUser or $wgLang 2011-12-11 10:16:32 +00:00
Siebrand Mazeland
850ca1fbdd Remove no longer needed RELEASE-NOTES-1.18. 2011-12-11 10:11:56 +00:00
Alexandre Emsenhuber
658f17dbee Use WikiPage instead of Article 2011-12-11 09:44:02 +00:00
Alexandre Emsenhuber
349d80a7d6 Use local context to get messages 2011-12-11 09:31:47 +00:00
Derk-Jan Hartman
a7f0e1e80a Add unit test for bug 32888
Follow up r105727
2011-12-10 22:50:28 +00:00
Aaron Schulz
3e26c05e80 * Fixed failing FlaggedRevs tests (one due global to leaks from a core test) and made it clean up the DB table afterwards 2011-12-10 20:08:58 +00:00
Alexandre Emsenhuber
56ca6662e8 Use WikiPage instead of Article 2011-12-10 20:03:19 +00:00
Alexandre Emsenhuber
641ca7bff0 Factorise calls to $this->getTitle() in SkinTemplate::outputPage() 2011-12-10 17:01:22 +00:00
Alexandre Emsenhuber
2629c3649f * Added revision's timestamp to OutputPage along with revision ID; avoid a DB hit in Skin::lastModified() when showing parser cache's content. This changed with the removal of $wgArticle in Skin since now it's a different WikiPage object and thus WikiPage::setTimetstamp() call is useless (but still kept).
* Added ParserOutput::(get|set)Timestamp() and the $mTimestamp member; avoid messing with isset()
2011-12-10 16:30:40 +00:00
Alexandre Emsenhuber
d1635b45cc Do the "user is allowed to edit" check when checking for protect rights with the same level of expensiveness as for the protect checks and also do "quick" checks since we don't care about the message names. This avoids a DB query for cascading protection on each page view for users with protect right. 2011-12-10 15:44:44 +00:00
Alexandre Emsenhuber
db0d813d05 * Group related functions
* Expand functions that were all declared in one line for consistency
* Removed big "Static functions" and "Other stuff" comments that are just confusing
2011-12-10 15:25:28 +00:00
Alexandre Emsenhuber
81ea10b635 * Changed WikiPage::exists() to call Title::exists()
* Changed some getId() calls to exists() and call that method directly on $mTitle
2011-12-10 09:35:03 +00:00
Aaron Schulz
e52f4fcb2a FU r105154: only clear tables that tests specify as written to. This reduces the obnoxious slowness that was getting in the way of FileBackend testing.
Since previously (pre-r105154) nothing was cleared, tests should still work.
2011-12-10 05:47:46 +00:00
Derk-Jan Hartman
934b01c67e Fix issue with sortable headers when nesting a table INSIDE a table header cell ?
Who comes up with these usecases ? :D

Fixes bug 32888
2011-12-09 22:39:04 +00:00
Raimond Spekking
4017e59a47 Localisation updates for core and extension messages from translatewiki.net 2011-12-09 20:31:37 +00:00
Aaron Schulz
6dcefd735f Added LoggableUserIPData hook to hooks.txt and made CheckUser handle it. This is needed for bug 32925. 2011-12-09 20:13:31 +00:00
Sam Reed
de7add90ce Followup r105575, r105619, r105671 Add RELEASE-NOTES-1.19 2011-12-09 14:48:34 +00:00
Sam Reed
a0b90c2aba 1.8.17 also 2011-12-09 14:46:28 +00:00
Tim Starling
71e27e22de * Revert r103476, r105161 and implement the fix for bug 32858 (a.k.a. bug 32450) in WikiPage instead. See comment 14 for further rationale.
* Clarified release notes. Please write what the new code does, not the bug description.
2011-12-09 10:32:55 +00:00
Tim Starling
82ff85e67c Fix for r102295 per CR r105654: don't double-escape the URL 2011-12-09 09:32:15 +00:00
Tim Starling
4be17a47f4 Revert r102504 (allow ESC in debug output): the justification in the comment above seems very reasonable to me, and is in fact an argument for stripping only ESC, since that's the only character that can change terminal modes. You could always make a highlighter pipe script for your wfDebugGreen(), instead of tailing the log directly. 2011-12-09 06:03:27 +00:00
Tim Starling
b36df6ecc6 Fixes for r102295:
* Rename getDiffText to getDiffLink since that's what it actually gets. Fix associated variable names. 
* Use Html::element() not Html::rawElement() when escaping is desired.
2011-12-09 05:54:26 +00:00