Added some more includes for commandfactory and fixed some things in the manager class