Svoboda | Graniru | BBC Russia | Golosameriki | Facebook
Jump to content

Help:Reverting

From mediawiki.org
PD Note: When you edit this page, you agree to release your contribution under the CC0. See Public Domain Help Pages for more info. PD

Reverting means restoring a page to an earlier version from its history.

Manual method

[edit]
  • Go to the page's "History " tab and select the time and date of the earlier version you want to revert to.
  • The selected version will display a message similar to this indicating it is an old revision: Revision as of 17:33, 27 June 2024 by Example (edit summary)
  • Click "edit this page " for that version.
  • When dealing with vandalism, ensure you revert to the last non-vandalized version, as there may be multiple vandal edits.
  • You will see a warning above the edit box saying, "Warning: You are editing an out-of-date revision of this page.

If you publish it, any changes made since this revision will be lost."

  • Ignore this warning and take note of the below before you save the page.
    • Use "revert" or "rv" in the edit summary and briefly explain.
    • You can wikilink the username or IP address involved:
      • Example for an IP address: Reverted edits by «IP address» to last revision by Alice
      • Example for a username: Reverted edits by Bob (talk) to last version by Alice
    • Use "rvv" for blatant vandalism.
  • Check the "history" tab again to ensure the vandalism is undone. If subsequent constructive edits were undone, redo them if possible.
  • Review the contribution history of the user who vandalized the page to see if they targeted multiple pages. If they have, report them to the administrators.

MediaWiki looks at the last 15 edits to see if the new edit matches any of them. If it does, the new edit gets the mw-manual-revert tag.

Undo

[edit]

You can undo an edit without affecting later changes. To do this, view the diff for that edit and click "undo". MediaWiki will try to create an edit page with the undesirable edits removed while keeping all later edits. You can also change the default edit summary and make further changes before saving.

This feature removes the need to redo useful changes after undoing an edit. However, it won't work if undoing the edit conflicts with subsequent edits. For example, if edit 1000 adds a paragraph and edit 1005 changes it, you can't automatically undo edit 1000. You'll have to fix this manually.

Before MediaWiki 1.36 , any edits initiated with the "undo" link were marked with the mw-undo change tag. Starting from MediaWiki 1.36 , any modifications made by the user before saving will not be marked as undos. This change prevents users from labeling arbitrary edits as 'undos'.

Rollback

[edit]

Administrators and authorized users with access to the tool have "rollback" links that:

  • Are visible only next to the most recent edit
  • Revert all subsequent edits by the last editor
  • Work instantly without a confirmation page
  • Add an automatic edit summary , "Reverted edits by Example2 (talk) to last version by Example", marking the edit as minor (m).

Rollback links are found on user contributions , history , and diff pages. On diff pages, rollback links can be misleading because they may not revert to the exact version shown. The diff page might display a combination of edits, including those by other editors, or only part of what the rollback button would undo. To accurately see what changes the rollback button will revert to, review the specific diff that compares the last version by the previous editor with the most recent version.

Rollback is faster than undo because of the following:

  • You can revert changes instantly without checking revisions or diffs.
  • No need to load an edit page or send text back to the server.
  • It doesn't require clicking the save button.

Unlike undo, rollback isn't as flexible since you can't choose which edits to undo. You might need to revert more or fewer edits than what rollback allows or edits that aren't the most recent. Rollback also doesn't let you add an explanation to the automatic edit summary. It's mainly used for quickly undoing clear cases of vandalism.

When you rollback a good-faith edit without explaining why, it can be misunderstood as implying the edit was as bad as vandalism and didn't merit an explanation. Some editors may take this personally. If you use rollback for reasons other than dealing with vandalism (like when undoing isn't feasible due to page size), it's polite to leave a note on the talk page or the user's talk page to clarify your reasons.

If someone else made changes or reverted the page before you clicked "rollback," or if there were no prior edits, you'll encounter an error message.

Bot rollback

[edit]

In cases of flood vandalism, administrators can hide it from recent changes by adding &bot=1 to the end of the URL for a user's contributions. For example, http://mediawiki.org/w/index.php?title=Special:Contributions&target=SomePersistentVandal&bot=1.

Clicking the rollback links on the contributions list hides both the reverted edit and the original edit from recent changes unless you click the "bots" link to set hidebots=0. These edits are still visible in contributions lists, page histories, and watchlists, and they remain in the database. This feature aims to prevent recent changes from being overwhelmed by mass vandalism and should only be used for such cases, not for undoing edits you just don't like.

Reverted edit change tag

[edit]

Since MediaWiki 1.36 , reverted edits are marked with the mw-reverted change tag. This applies to all three methods mentioned earlier, with these additional conditions:

  • The number of reverted edits must be less than or equal to $wgRevertedTagMaxDepth (default is 15).
  • The reverting edit must not be marked as reverted or deleted .

The mw-reverted tag is added soon after a revert if the edit is automatically approved. What automatically approved means can differ depending on your wiki's settings:

  • If patrolling is enabled on your wiki, auto-approval makes the edit autopatrolled, so only users with the autopatrol user right will see their reverted tag applied immediately.
  • If your wiki uses an extension like FlaggedRevs , it can tell MediaWiki if the edit is auto-approved. How this is determined depends on the extension.

If the edit isn't auto-approved, the reverted tag will be added later after it's been approved, patrolled, or reviewed.

The approval system prevents vandals from marking many edits as reverted, which would make the reverted tag useless. If your wiki uses an edit review process properly, it should be unnoticed by editors making good edits.

FlaggedRevs

[edit]

If your wiki uses the FlaggedRevs extension, a revert will be auto-approved if any of these conditions apply:

  • FlaggedRevs isn't used on the page.
  • The user has autoreview rights.
  • The user is reverting their own edit.
  • The edit meets the criteria to be autoreviewed.

If the revert wasn't auto-approved, it can be approved later by reviewing the edit.

When to revert

[edit]

Dos

[edit]
  • Reverting edits should be done with caution.
  • It's often used to stop vandalism and similar abuse.
  • If you're unsure about doing a revert, discuss it on the talk page first.
  • You can revert your edit if you realize it is wrong, but check if others have made changes first.
  • If only a part of an edit is problematic, just fix that part instead of reverting the whole thing.

Don'ts

[edit]
  • Don't leave unnecessary or poorly written material in place, as this can be a disservice to the reader. Good intentions aside, it's important to maintain quality.
  • If your edit is reverted, don't take it personally; not everything fits into the scope of the wiki.
  • Problematic sections or changes should be improved, not deleted, if they contain valid information.
  • If it's hard to determine the truth or usefulness of a claim, discuss it on the talk page. As a last resort, move biased material to the talk page instead of deleting it.

Revert wars

[edit]

Revert wars are usually seen as harmful for these reasons:

  1. They create bad feelings among users, disrupt articles, and make other editors hesitant to contribute.
  2. They waste database space, clutter the page history , and flood recent changes and watchlists.
  3. Some editors may feel hurt by reverts, thinking their hard work was dismissed.
  4. They often cause inconsistencies in articles because editors focus only on one part without considering the whole.

Hence, editors shouldn't revert just because they disagree. Instead, they can discuss their objections on a talk page or use dispute resolution processes.

Explain reverts

[edit]

When you revert an edit, explain why so the editor can understand why it happened. This allows them the opportunity to make revisions that address the identified issue.

Giving reasons for reversions helps other editors understand if they need to check reverted content, like when a page is blanked. Clear communication prevents misunderstandings and edit wars. It also informs readers about the reliability and how current the information on the page is.

Consider leaving a note on the Talk page if your reason is too long to be placed in an edit summary . It's often better to discuss first before reverting, giving the other editor a chance to understand and possibly adjust their edit. Similarly, if your edit is reverted without explanation, wait a bit to see if the other editor provides clarification on the talk page or your own.