Some fixes for the next pull request