more helpers added and numerous bug fixes