summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlon Levy <alon@pobox.com>2014-10-13 14:27:14 +0300
committerAlon Levy <alon@pobox.com>2014-10-13 14:28:20 +0300
commite9ffa13517464da38d2f87d1673763db0e4136a5 (patch)
tree18f07549dffdf1296ce6499f0434d9740c160275
parentbe535ef7a62c854b566e464d2f67ce93c8776402 (diff)
Fixes #95 no double text in central node of star graphPrototype
-rw-r--r--scripts/textanalysis.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/scripts/textanalysis.js b/scripts/textanalysis.js
index 0b9318b7..2776c37e 100644
--- a/scripts/textanalysis.js
+++ b/scripts/textanalysis.js
@@ -222,8 +222,10 @@ var textAnalyser2 = function (newtext, finalize) {
}
}
+ abnormalGraph = (newlinks.length - ANDcount) >= 3;
+
//PREFIX not null case - put complete sentence in first link.
- if (prefix) {
+ if (prefix && !abnormalGraph) {
newlinks[1] = prefix + " " + newnodes[0] +
(newlinks[1] !== undefined || newnodes[1] !== undefined ?
" " : "")
@@ -272,7 +274,6 @@ var textAnalyser2 = function (newtext, finalize) {
addNode("", "bubble","temp");
}
- abnormalGraph = (newlinks.length - ANDcount) >= 3;
//0-N ORDER STACK
for (m = 0; m < orderStack.length - 1; m++) {