Adapted to new design