Fixes issues pointed out in the PR comments