Added distribution logic