bug fix from Hal