implemented David's recommendations