Consistent naming and small bug fixes