update to match upstream

update fork with updates to master

(In case this pull request goes to Paul, I'm trying to update my fork with your recent changes)