alternate fix for #508

#508