some more meat added to the code