fix for #440 (bug introduced in commit before)