[wp-trac] [WordPress Trac] #22840: Uploading an existing plugin saves the zip in media library

WordPress Trac noreply at wordpress.org
Fri Sep 13 07:10:19 UTC 2013


#22840: Uploading an existing plugin saves the zip in media library
-----------------------------+--------------------
 Reporter:  Ipstenu          |       Owner:
     Type:  defect (bug)     |      Status:  new
 Priority:  normal           |   Milestone:  3.7
Component:  Upgrade/Install  |     Version:  3.4.2
 Severity:  normal           |  Resolution:
 Keywords:                   |
-----------------------------+--------------------

Comment (by dd32):

 This occurs because in the event of a falsey (in this case, a null) result
 from the Upgrader, it assumes that the FTP credentials have been
 requested.
 At that point, it switches from an upload, to simply a install-from-local-
 file situation, after which, it deletes the attachment it's installing
 from.

 The problem here though, is that there is no current way to distinguish
 that the return value from Plugin_Upgrader::install() was a "Hang on, we
 just need to ask this person for some credentials", verses, "Yeah, We
 can't install this zip..".

 attachment:22840.diff is an untested POC patch for a way around it for
 now.

--
Ticket URL: <http://core.trac.wordpress.org/ticket/22840#comment:5>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list