cleaning input containers, so that IPEs do not create an infinite number elements

pull/6827/head
Gregor Schmidt 14 years ago
parent d71eb2bef5
commit ebc20cbf95
  1. 6
      assets/javascripts/app/editable_inplace.js

@ -10,10 +10,8 @@ RB.EditableInplace = (function ($) {
},
getEditor: function () {
// Create the model editor if it does not yet exist
//
// TODO: Review usage of editor and editor.length
var editor = this.$.children(".editors").first();
// Create the model editor container if it does not yet exist
var editor = this.$.children(".editors").first().html('');
if (editor.length === 0) {
editor = $("<div class='editors'></div>").appendTo(this.$);

Loading…
Cancel
Save