- Add more info to detect errors.

This commit is contained in:
Paulo Gustavo Veiga 2012-09-24 13:11:11 -03:00
parent d2f9749d61
commit 155ec74dea
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(); var designerTopics = this._designer.getModel().getTopics();
return designerTopics.filter(function (topic) { var result = designerTopics.filter(function (topic) {
return topicsIds.contains(topic.getId()); 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) { deleteTopic:function (topic) {

View File

@ -341,7 +341,7 @@ public class FreemindImporter
* 3 -> 2 * 3 -> 2
* 4 -> 4 * 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>(); final List<Node> nodes = new ArrayList<Node>();
int result; int result;