fixed bug reported by Sheel Shah