updating some small tweaks to the code