updates according to feedback by @sirthias