Some bugfixes
Merge branch 'master' into gh-pages
Update