Made things compatable with refactoring done by tom.