mirror of
https://github.com/discourse/discourse.git
synced 2024-11-25 02:11:08 -06:00
ec3758b573
* FIX: Preserve field types when updating revision When a post was edited quickly twice by the same user, the old post revision was updated with the newest changes. To check if the change was reverted (i.e. rename topic A to B and then back to A) a comparison of the initial value and last value is performed. If the check passes then the intermediary value is dismissed and only the initial value and the last ones are preserved. Otherwise, the modification is dismissed because the field returned to its initial value. This used to work well for most fields, but failed for "tags" because the field is an array and the values were transformed to strings to perform the comparison. * FIX: Reset last_editor_id if revision is reverted If a post was revised and then the same revision was reverted, last_editor_id was still set to the ID of the user who last edited the post. This was a problem because the same person could then edit the same post again and because it was the same user and same post, the system attempted to update the last one (that did not exist anymore). |
||
---|---|---|
.. | ||
components | ||
fabricators | ||
fixtures | ||
helpers | ||
import_export | ||
initializers | ||
integration | ||
integrity | ||
jobs | ||
lib | ||
mailers | ||
models | ||
multisite | ||
requests | ||
script/import_scripts | ||
serializers | ||
services | ||
support | ||
tasks | ||
views/omniauth_callbacks | ||
rails_helper.rb | ||
swagger_helper.rb |