Index: lams_central/web/lams_authoring.swf =================================================================== diff -u -r6ee8cd168d2101e85d6481bb8ea8d8cea125ccf1 -r787440b6e10d137b05e2c864bb25255d17a76650 Binary files differ Index: lams_central/web/lams_authoring_library.swf =================================================================== diff -u -r6ee8cd168d2101e85d6481bb8ea8d8cea125ccf1 -r787440b6e10d137b05e2c864bb25255d17a76650 Binary files differ Index: lams_flash/src/central/flash/org/lamsfoundation/lams/authoring/cmpt/CompetenceDefinitionDialog.as =================================================================== diff -u -r712d6bf4194c9a9dbdc67b739fbb2fcbcf2711f1 -r787440b6e10d137b05e2c864bb25255d17a76650 --- lams_flash/src/central/flash/org/lamsfoundation/lams/authoring/cmpt/CompetenceDefinitionDialog.as (.../CompetenceDefinitionDialog.as) (revision 712d6bf4194c9a9dbdc67b739fbb2fcbcf2711f1) +++ lams_flash/src/central/flash/org/lamsfoundation/lams/authoring/cmpt/CompetenceDefinitionDialog.as (.../CompetenceDefinitionDialog.as) (revision 787440b6e10d137b05e2c864bb25255d17a76650) @@ -211,7 +211,6 @@ if (competenceName.length == 0) { LFMessage.showMessageAlert(Dictionary.getValue("competence_editor_warning_title_blank"), null); - } else if (app.getDesignDataModel().competences.containsKey(competenceName)) { // entry already exists, do not add @@ -234,36 +233,46 @@ var updatedCompetenceName:String = StringUtils.trim(competence_title_txt.text); var updatedCompetenceDesc:String = StringUtils.trim(competence_description_txt.text); - if (editingCompetence != null && editingCompetence != undefined && app.getDesignDataModel().competences.containsKey(editingCompetence)) { - if (updatedCompetenceName.length > 0) { - app.getDesignDataModel().competences.remove(editingCompetence); // remove the original competencetitle - app.getDesignDataModel().competences.put(updatedCompetenceName, updatedCompetenceDesc); - - // if the competence title has changed, update the mappings for all activities to the new competence title - if (editingCompetence != updatedCompetenceName) { - - var activityKeys:Array = app.getDesignDataModel().activities.keys(); // contains the activity UIIDs - - for (var i=0; i 0) { + app.getDesignDataModel().competences.remove(editingCompetence); // remove the original competencetitle + app.getDesignDataModel().competences.put(updatedCompetenceName, updatedCompetenceDesc); + + // if the competence title has changed, update the mappings for all activities to the new competence title + if (editingCompetence != updatedCompetenceName) { + + var activityKeys:Array = app.getDesignDataModel().activities.keys(); // contains the activity UIIDs + + for (var i=0; i