Fixed bug in RPMD when using contractions