Fixed ComponentTypeCommands.setUnit to support unit == null