Fixed #86, Fixed #87

Sorry about the bit of sloppiness