Patch for two issues.
If you run in to any problems please file an issue following all the guidelines, as we need all the requested information to be able to help.