Opened 2 years ago

Closed 2 years ago

Last modified 2 years ago

#15922 closed defect (bug) (fixed)

WP_MS_Themes_List_Table plural

Reported by: scribu Owned by: ocean90
Priority: normal Milestone: 3.1
Component: Security Version:
Severity: minor Keywords: needs-patch
Cc:

Description

Currently, the plural is set to 'plugins'. This is a hack to avoid duplicating CSS.

The problem is that the plural is used for generating the nonce too.

The attached patch limits the hack to only the CSS class, allowing the correct nonce to be generated and checked.

Attachments (2)

15922.diff (731 bytes) - added by scribu 2 years ago.
15922.css1.patch (5.8 KB) - added by ocean90 2 years ago.

Download all attachments as: .zip

Change History (15)

scribu2 years ago

Can we not just add themes to the CSS file in the relevant places too?

  • Owner set to ocean90
  • Status changed from new to assigned

ocean902 years ago

15922.css1.patch is the first pass.

(Discussion on IRC)

I hesitated to add the styles, since I think it would be better if we had a single, generic 'themesorplugins' class (with a better name obviously).

comment:5 follow-up: ↓ 6   ocean902 years ago

Decision from scribu, JohnONolan and me. Keep the .plugins class and add instead of the .themes class a more generic class name, which we will use for the plugins and themes list. Proposals for a name?

(Sitenote: We need to find a way to deprecate CSS.)

Last edited 2 years ago by ocean90 (previous) (diff)

comment:6 in reply to: ↑ 5   ryan2 years ago

Replying to ocean90:

Decision from scribu, JohnONolan and me. Keep the .plugins class and add instead of the .themes class a more generic class name, which wil will use for the plugins and themes list. Suggestions?

Fine by me.

comment:7   ryan2 years ago

Per IRC discussion, we're going with the simple, conservative 15922.diff patch and whatever nonce fixes that requires.

I believe 15922.diff fixes the nonces, yes?

The 'bulk-themes' nonce is already set in /network/themes.php but it doesn't seem to be checked anywhere. If it were, there would be some errors, without this patch.

  • Resolution set to fixed
  • Status changed from assigned to closed

(In [17115]) Set the correct plural. Use plugins class on the table. Props scribu. fixes #15922

  • Keywords needs-patch added; has-patch removed
  • Resolution fixed deleted
  • Status changed from closed to reopened

As stated above, the nonce check is missing.

  • Resolution set to fixed
  • Status changed from reopened to closed

(In [17121]) Check bulk-themes nonce before bulk delete. fixes #15922

There are other places that need nonces. We can audit them in a dedicated ticket.

Note: See TracTickets for help on using tickets.