Commit 1429391d authored by helene ortiz's avatar helene ortiz
Browse files

No commit message

No commit message
parent aacf77e3
......@@ -22,6 +22,7 @@ import java.util.HashMap;
import java.util.Map;
import fr.ill.ics.bridge.Controller;
import fr.ill.ics.bridge.command.AtomicCommandWrapper;
import fr.ill.ics.nscclient.dataprovider.CommandDatabase;
import fr.ill.ics.nscclient.servant.CorbaServant;
......@@ -52,7 +53,13 @@ public class CommandManager {
controllerCommands.put(controller, new HashMap());
int servantId = ((CorbaServant)controller).getId();
int servantId;
if (controller instanceof CorbaServant) {
servantId = ((CorbaServant)controller).getId();
} else {
servantId = ((AtomicCommandWrapper)controller).getId();
// Create a new command if it doesn't already exist or just retrieve it from the Map
Map allCommands = (HashMap)controllerCommands.get(controller);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment