[wp-trac] [WordPress Trac] #7392: Don't create new autosave revision if nothing has changed yet

WordPress Trac noreply at wordpress.org
Wed Jul 24 04:33:25 UTC 2013


#7392: Don't create new autosave revision if nothing has changed yet
-------------------------------------------------+-------------------------
 Reporter:  Otto42                               |       Owner:  westi
     Type:  defect (bug)                         |      Status:  reopened
 Priority:  normal                               |   Milestone:  3.6
Component:  Autosave                             |     Version:  2.6
 Severity:  minor                                |  Resolution:
 Keywords:  has-patch needs-testing autosave-    |
  redo close                                     |
-------------------------------------------------+-------------------------
Changes (by nacin):

 * milestone:  Awaiting Review => 3.6


Comment:

 MarkJaquith and I ran into this again while working on #24804. (This is a
 bit more noticable in the new revisions UI.) I came to the same conclusion
 azaozz happened to have reached months ago in [comment:14 comment 14]:
  > This happens only when the Visual editor is default (is shown first).
 Caused by running the post_content through wpautop before outputting it in
 the textarea (TinyMCE needs the <p>), so the first `autosaveLast` (used to
 determine if something has changed) gets post_content with <p> and is
 later compared to post_content without <p>.
 >
 > There are better ways to do that, should be fixed with the autosave
 updates in 3.6.

 It's not yet fixed, but [attachment:7392.3.diff] does it.

 I agree with fixing this in JS still — so let's do it.

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


More information about the wp-trac mailing list