this should fix BR #377 - needs to be tested