Make WordPress Core

Opened 7 years ago

Last modified 7 years ago

#39794 reviewing defect (bug)

Notice if update_plugins cap is off

Reported by: sebastianpisula's profile sebastian.pisula Owned by: sergeybiryukov's profile SergeyBiryukov
Milestone: Future Release Priority: normal
Severity: normal Version:
Component: Plugins Keywords: has-patch
Focuses: Cc:

Description

In wp-admin/includes/update.php:378 i have condition:

<?php
if ( ! current_user_can( 'update_plugins' ) ) {

then in plugins lists I should see notice "There is a new version of %1$s available. View version %4$s details"

But I don't see notice.

I think that problem is in wp_plugin_update_rows() function

Attachments (7)

39794.patch (647 bytes) - added by sebastian.pisula 7 years ago.
397941.patch (3.3 KB) - added by sebastian.pisula 7 years ago.
previous filter + fix context translation
39794.2.patch (652 bytes) - added by sebastian.pisula 4 years ago.
Updated patch for WP Version 5.5.1
Screenshot 2020-10-13 at 14.27.16.png (625.9 KB) - added by sebastian.pisula 4 years ago.
Screen shows how it should works.
Screenshot 2020-10-13 at 14.23.10.png (637.4 KB) - added by sebastian.pisula 4 years ago.
Screen shows how it works now.
Screenshot 2020-10-13 at 14.22.49.png (695.5 KB) - added by sebastian.pisula 4 years ago.
Screen shows how it works now when I logged in as administrator.
39794.3.patch (2.3 KB) - added by sebastian.pisula 4 years ago.

Download all attachments as: .zip

Change History (12)

@sebastian.pisula
7 years ago

previous filter + fix context translation

#1 @sebastian.pisula
7 years ago

I add context because in Polish translation is error and I think that context will be helpful for translators.

#. translators: 1: theme name, 2: theme details URL, 3: additional link
#. attributes, 4: version number
#. translators: 1: plugin name, 2: details URL, 3: additional link attributes,
#. 4: version number
#. translators: 1: theme name, 2: details URL, 3: additional link attributes,
#. 4: version number
#: wp-admin/includes/theme.php:181 wp-admin/includes/update.php:380
#: wp-admin/includes/update.php:525
msgid "There is a new version of %1$s available. <a href=\"%2$s\" %3$s>View version %4$s details</a>."
msgstr "Dostępna jest nowa wersja motywu %1$s. <a href=\"%2$s\" %3$s>Zobacz informacje o wersji %4$s</a>."

#2 @SergeyBiryukov
7 years ago

  • Milestone changed from Awaiting Review to 4.8
  • Owner set to SergeyBiryukov
  • Status changed from new to reviewing

#3 @bhargavbhandari90
7 years ago

  • Keywords has-patch added
Last edited 7 years ago by bhargavbhandari90 (previous) (diff)

This ticket was mentioned in Slack in #core by flixos90. View the logs.


7 years ago

#5 @flixos90
7 years ago

  • Milestone changed from 4.8 to Future Release

@sebastian.pisula
4 years ago

Updated patch for WP Version 5.5.1

@sebastian.pisula
4 years ago

Screen shows how it should works.

@sebastian.pisula
4 years ago

Screen shows how it works now.

@sebastian.pisula
4 years ago

Screen shows how it works now when I logged in as administrator.

Note: See TracTickets for help on using tickets.