Fix problem with local/remote origins mixed