second attempt to resolve bug #39