addressing issues mentioned in #405