fix remarks in #248

see 7ebb52c, all the rest is sync with `develop` branch