Small changes to code based on debugging run in #test.  Modified functionality of Command Factory Pattern.