Merge branch 'fix-template-sorting' of https://github.com/pythongosssss/ComfyUI

This commit is contained in:
comfyanonymous 2023-12-03 22:51:23 -05:00
commit 6efe561c2a
1 changed files with 1 additions and 1 deletions

View File

@ -164,7 +164,7 @@ class ManageTemplates extends ComfyDialog {
var prev_i = el.dataset.id;
if ( el == this.draggedEl && prev_i != i ) {
[this.templates[i], this.templates[prev_i]] = [this.templates[prev_i], this.templates[i]];
this.templates.splice(i, 0, this.templates.splice(prev_i, 1)[0]);
}
el.dataset.id = i;
});