Skip to content
Snippets Groups Projects
Commit d67c5ca5 authored by John Schihada's avatar John Schihada
Browse files

Fixed bug

parent 320d5295
No related branches found
No related tags found
No related merge requests found
......@@ -104,6 +104,13 @@ public class ScrollAssignment
public OMS assignment;
}
public class ScrollApplicationInfo
{
public Boolean valid;
public ScrollApplicationCheckingError[] errors;
public List<Scroll.ScrollFact> acquiredFacts;
}
public class ScrollDynamicInfo
{
public Scroll original;
......
......@@ -72,8 +72,9 @@ public void magicButton()
PushoutFactFailEvent.Invoke(null);
return;
}
List<Scroll.ScrollFact> pushoutFacts = JsonConvert.DeserializeObject<List<Scroll.ScrollFact>>(answer);
readPushout(pushoutFacts);
Scroll.ScrollApplicationInfo pushout = JsonConvert.DeserializeObject<Scroll.ScrollApplicationInfo>(answer);
readPushout(pushout.acquiredFacts);
}
public void newAssignment()
......@@ -148,7 +149,11 @@ private void readPushout(List<Scroll.ScrollFact> pushoutFacts)
}
public void processScrollDynamicInfo(Scroll.ScrollDynamicInfo scrollDynamicInfo) {
LatestCompletions = scrollDynamicInfo.completions[0];
if (scrollDynamicInfo.completions.Count != 0)
LatestCompletions = scrollDynamicInfo.completions[0];
else
LatestCompletions = new List<Scroll.ScrollAssignment>();
List<string> completionUris = new List<string>();
foreach (Scroll.ScrollAssignment currentCompletion in LatestCompletions) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment