admin: Fix pull#470 edit-abort-save with <pre>

FREEZE-blogpost-2021-01-20
Felix 2021-01-19 18:34:38 +01:00
parent e1a708d075
commit 2c16304c26
2 changed files with 3 additions and 3 deletions

View File

@ -73,7 +73,7 @@ function start_edit(com_id) {
var editable_elements = ['isso-author-' + com_id,
'isso-email-' + com_id,
'isso-website-' + com_id,
'isso-text-' + com_id];
'isso-text-pre-' + com_id];
for (var idx=0; idx <= editable_elements.length; idx++) {
set_editable(editable_elements[idx]);
}
@ -85,7 +85,7 @@ function stop_edit(com_id, save_changes) {
var editable_elements = ['isso-author-' + com_id,
'isso-email-' + com_id,
'isso-website-' + com_id,
'isso-text-' + com_id];
'isso-text-pre-' + com_id];
for (var idx=0; idx <= editable_elements.length; idx++) {
unset_editable(editable_elements[idx], save_changes);
}

View File

@ -124,7 +124,7 @@
{% if comment.mode == 4 %}
<strong>HIDDEN</strong>. Original text: <br />
{% endif %}
<div id="isso-text-{{comment.id}}"><pre>{{comment.text}}</pre></div>
<div id="isso-text-{{comment.id}}"><pre id="isso-text-pre-{{comment.id}}">{{comment.text}}</pre></div>
</div>
<div class='isso-comment-footer'>
{% if conf.votes and comment.likes - comment.dislikes != 0 %}