Added minor changes to facilitate new functionality