Index: trunk/extensions/DidYouMean/DidYouMean.php |
— | — | @@ -203,7 +203,7 @@ |
204 | 204 | if ($article->getTitle()->getNamespace() != 0 || $article->isRedirect() == true) |
205 | 205 | return true; |
206 | 206 | |
207 | | - wfDoInsert( $article->getID(), $article->getTitle()->getText() ); |
| 207 | + wfDymDoInsert( $article->getID(), $article->getTitle()->getText() ); |
208 | 208 | |
209 | 209 | return true; |
210 | 210 | } |
— | — | @@ -229,7 +229,7 @@ |
230 | 230 | if ($article->getTitle()->getNamespace() != 0 || $article->isRedirect() == true) |
231 | 231 | return true; |
232 | 232 | |
233 | | - wfDoDelete( $article->getID() ); |
| 233 | + wfDymDoDelete( $article->getID() ); |
234 | 234 | |
235 | 235 | return true; |
236 | 236 | } |
— | — | @@ -257,11 +257,11 @@ |
258 | 258 | #} |
259 | 259 | |
260 | 260 | if ($oldns == 0 && $newns == 0) { |
261 | | - wfDoUpdate( $pageid, $newtitletext ); |
| 261 | + wfDymDoUpdate( $pageid, $newtitletext ); |
262 | 262 | } elseif ($oldns == 0) { |
263 | | - wfDoDelete( $pageid ); |
| 263 | + wfDymDoDelete( $pageid ); |
264 | 264 | } elseif ($newns == 0) { |
265 | | - wfDoInsert( $pageid, $newtitletext ); |
| 265 | + wfDymDoInsert( $pageid, $newtitletext ); |
266 | 266 | } |
267 | 267 | |
268 | 268 | return true; |
— | — | @@ -288,10 +288,10 @@ |
289 | 289 | |
290 | 290 | if ($article->isRedirect($text)) { |
291 | 291 | if (!$wgParser->mDymRedirBeforeEdit && !($flags & EDIT_NEW)) |
292 | | - wfDoDelete( $article->getID() ); |
| 292 | + wfDymDoDelete( $article->getID() ); |
293 | 293 | } else { |
294 | 294 | if ($wgParser->mDymRedirBeforeEdit || $flags & EDIT_NEW) |
295 | | - wfDoInsert( $article->getID(), $article->getTitle()->getText() ); |
| 295 | + wfDymDoInsert( $article->getID(), $article->getTitle()->getText() ); |
296 | 296 | } |
297 | 297 | |
298 | 298 | $wgParser->mDymRedirBeforeEdit = false; |
— | — | @@ -299,7 +299,7 @@ |
300 | 300 | return true; |
301 | 301 | } |
302 | 302 | |
303 | | -function wfDoInsert( $pageid , $title ) { |
| 303 | +function wfDymDoInsert( $pageid , $title ) { |
304 | 304 | wfDebug( 'HIPP: ' . __METHOD__ . " INSERT\n" ); |
305 | 305 | $dbw = wfGetDB( DB_MASTER ); |
306 | 306 | |
— | — | @@ -318,12 +318,12 @@ |
319 | 319 | $dbw->insert( 'dympage', array( 'dp_pageid' => $pageid, 'dp_normid' => $normid ) ); |
320 | 320 | |
321 | 321 | # touch all pages which will now link here |
322 | | - wfTouchPages( "dp_normid=$normid" ); |
| 322 | + wfDymTouchPages( "dp_normid=$normid" ); |
323 | 323 | |
324 | 324 | } |
325 | 325 | |
326 | 326 | |
327 | | -function wfTouchPages( $condition ) { |
| 327 | +function wfDymTouchPages( $condition ) { |
328 | 328 | global $wgDBtype; |
329 | 329 | |
330 | 330 | $dbw = wfGetDB( DB_MASTER ); |
— | — | @@ -341,7 +341,7 @@ |
342 | 342 | |
343 | 343 | } |
344 | 344 | |
345 | | -function wfDoDelete( $pageid ) { |
| 345 | +function wfDymDoDelete( $pageid ) { |
346 | 346 | wfDebug( 'HIPP: ' . __METHOD__ . " DELETE\n" ); |
347 | 347 | $dbw = wfGetDB( DB_MASTER ); |
348 | 348 | |
— | — | @@ -355,10 +355,10 @@ |
356 | 356 | $dbw->delete( 'dymnorm', array('dn_normid' => $normid) ); |
357 | 357 | |
358 | 358 | # touch all pages which will now link here |
359 | | - wfTouchPages( "dp_normid=$normid" ); |
| 359 | + wfDymTouchPages( "dp_normid=$normid" ); |
360 | 360 | } |
361 | 361 | |
362 | | -function wfDoUpdate( $pageid, $title ) { |
| 362 | +function wfDymDoUpdate( $pageid, $title ) { |
363 | 363 | wfDebug( 'HIPP: ' . __METHOD__ . " MOVE\n" ); |
364 | 364 | $dbw = wfGetDB( DB_MASTER ); |
365 | 365 | |
— | — | @@ -385,7 +385,7 @@ |
386 | 386 | $dbw->delete( 'dymnorm', array('dn_normid' => $oldnormid) ); |
387 | 387 | |
388 | 388 | # touch all pages which linked to the old name or will link to the new one |
389 | | - wfTouchPages( "(dp_normid=$normid OR dp_normid=$oldnormid)" ); |
| 389 | + wfDymTouchPages( "(dp_normid=$normid OR dp_normid=$oldnormid)" ); |
390 | 390 | |
391 | 391 | } |
392 | 392 | } |