Skip to content

Commit

Permalink
Bugfix: The help list could contain duplicated entries when a
Browse files Browse the repository at this point in the history
SelectPanel content changed. Now, the merged help entries are wiped
out before adding the new set.

git-svn-id: svn://cherokee-project.com/CTK/trunk@4608 5dc97367-97f1-0310-9951-d761b3857238
  • Loading branch information
alobbs committed Mar 28, 2010
1 parent ab12353 commit 204dbd5
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion static/js/Help.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,16 @@ function toggleHelp() {
function Help_add_entries (helps) {
var help = $('.help:first');

/* Remove previously merged entries
*/
$('.help_entry.merged').remove();

/* Add new entries
*/
for (var tmp in helps) {
var name = helps[tmp][0];
var file = helps[tmp][1];

help.append ('<div class="help_entry"><a href="/help/'+file+'.html">'+name+'</a></div>');
help.append ('<div class="help_entry merged"><a href="/help/'+file+'.html">'+name+'</a></div>');
}
}

0 comments on commit 204dbd5

Please sign in to comment.