- Add more info to detect errors.

This commit is contained in:
Paulo Gustavo Veiga 2012-09-24 13:11:11 -03:00
parent 56ac4aaed3
commit acd149bfc9
2 changed files with 5 additions and 2 deletions

View File

@ -242,9 +242,12 @@ mindplot.CommandContext = new Class({
}
var designerTopics = this._designer.getModel().getTopics();
return designerTopics.filter(function (topic) {
var result = designerTopics.filter(function (topic) {
return topicsIds.contains(topic.getId());
});
$assert(result.length == topicsIds.length, "Could not find topic. Result:" + result + ", Filtered:" + topicsIds + ", Current Topics: " + designerTopics);
return result;
},
deleteTopic:function (topic) {

View File

@ -341,7 +341,7 @@ public class FreemindImporter
* 3 -> 2
* 4 -> 4
*/
private int calcFirstLevelOrder(@NotNull List<Object> freeChilden, @NotNull Node freeChild) {
private int calcFirstLevelOrder(@NotNull List<Object> freeChilden, @Nullable Node freeChild) {
final List<Node> nodes = new ArrayList<Node>();
int result;