Squashed remaining bugs