implement suggestion by donkult (thanks!)