From: daniel Date: Fri, 6 Sep 2019 13:58:31 +0000 (+0200) Subject: DifferenceEngine: show undo links for non-text content X-Git-Tag: 1.34.0-rc.0~355^2 X-Git-Url: http://git.cyclocoop.org/%7B%24www_url%7Dadmin/%7B%7Blocalurle:Project:%C3%A7%C2%94%C2%BB%C3%A5%C2%83%C2%8F%C3%A5%C2%88%C2%A9%C3%A7%C2%94%C2%A8%C3%A3%C2%81%C2%AE%C3%A6%C2%96%C2%B9%C3%A9%C2%87%C2%9D%7D%7D%22?a=commitdiff_plain;h=8041b1ff890b20739dbe3fb3fdacf3b7e819fb6d;p=lhc%2Fweb%2Fwiklou.git DifferenceEngine: show undo links for non-text content In Ia94521b78 I introduced code that would suppress undo links in diffs of non-textual content. However, extensions that define non-textual content, such as Wikibase, may override action handles to provide undo functionality. So my reasoning for removing these links was flawed. Bug: T232214 Change-Id: I0316d8c0683b0782b9940e0e1e8f70d5bcb6b468 --- diff --git a/includes/diff/DifferenceEngine.php b/includes/diff/DifferenceEngine.php index b8697e53bd..7fcda4c728 100644 --- a/includes/diff/DifferenceEngine.php +++ b/includes/diff/DifferenceEngine.php @@ -1511,10 +1511,6 @@ class DifferenceEngine extends ContextSource { private function userCanEdit( Revision $rev ) { $user = $this->getUser(); - if ( !$rev->getContentHandler()->supportsDirectEditing() ) { - return false; - } - if ( !$rev->userCan( RevisionRecord::DELETED_TEXT, $user ) ) { return false; }