diff --git a/kallithea/templates/admin/gists/edit.html b/kallithea/templates/admin/gists/edit.html --- a/kallithea/templates/admin/gists/edit.html +++ b/kallithea/templates/admin/gists/edit.html @@ -85,8 +85,8 @@ var myCodeMirror = initCodeMirror("editor_${h.FID('f',file.path)}", "${request.script_name}", ''); //inject new modes - var $modes_select = $('#mimetype_${h.FID('f',file.path)}'); - $modes_select.each(function(){ + var $mimetype_select = $('#mimetype_${h.FID('f',file.path)}'); + $mimetype_select.each(function(){ var modes_select = this; var index = 1; for(var i=0;i diff --git a/kallithea/templates/admin/gists/new.html b/kallithea/templates/admin/gists/new.html --- a/kallithea/templates/admin/gists/new.html +++ b/kallithea/templates/admin/gists/new.html @@ -63,8 +63,8 @@ var myCodeMirror = initCodeMirror('editor', "${request.script_name}", ''); //inject new modes - var $modes_select = $('#mimetype'); - $modes_select.each(function(){ + var $mimetype_select = $('#mimetype'); + $mimetype_select.each(function(){ var modes_select = this; var index = 1; for(var i=0;i