Bucket

fixed the logic bug in the two step implementation