Fixed sampler bug