redesign logic for contrib II